Home » U++ Library support » CalendarCtrl » DropTime and WhenAction() problem
DropTime and WhenAction() problem [message #26361] |
Tue, 27 April 2010 16:35 |
|
koldo
Messages: 3358 Registered: August 2008
|
Senior Veteran |
|
|
Hello all
Using DropTime I have a problem: both selecting an hour with the mouse and entering a single key launch WhenAction().
Is there a way to launch different events from accepting an hour or date, and clicking a key?.
The problem is that in my program changing a DropTime hour launches a process that lasts some seconds to complete. As entering keys launches WhenAction, the program and control gets blocked. This way I cannot link left mouse clicking with a program action.
The CtrlLib source is this. When Action is marked with this <<<---:
EditField.cpp
bool EditField::Key(dword key, int rep)
{
...
switch(key) {
...
default:
if(key >= ' ' && key < 65536 || key == K_SHIFT_SPACE) {
if(!RemoveSelection()) SaveUndo();
while(rep--)
Insert(key == K_SHIFT_SPACE ? ' ' : key);
Action(); <<<---
return true;
}
DateTimeCtrl.cpp
void Calendar::LeftDown(Point p, dword keyflags)
{
...
if(PopUpCtrl::IsPopUp())
{
sel = tm;
Deactivate();
WhenAction(); <<<---
}
Best regards
Iñaki
|
|
|
|
Goto Forum:
Current Time: Sun Apr 28 23:01:08 CEST 2024
Total time taken to generate the page: 0.05365 seconds
|