|
[Audacity-cvs] audacity-src/src/widgets TimeTextCtrl.cpp, 1.46, 1.47
From: Leland Lucius <llucius@us...> - 2007-02-19 06:25
|
Update of /cvsroot/audacity/audacity-src/src/widgets
In directory sc8-pr-cvs11.sourceforge.net:/tmp/cvs-serv12029/widgets
Modified Files:
TimeTextCtrl.cpp
Log Message:
Fix keyboard handling of uncaptured keys
Fix crash after changing time format in selectionbar
Index: TimeTextCtrl.cpp
===================================================================
RCS file: /cvsroot/audacity/audacity-src/src/widgets/TimeTextCtrl.cpp,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -d -r1.46 -r1.47
--- TimeTextCtrl.cpp 18 Nov 2006 07:17:19 -0000 1.46
+++ TimeTextCtrl.cpp 19 Feb 2007 06:25:51 -0000 1.47
@@ -321,6 +321,10 @@
TimeTextCtrl::~TimeTextCtrl()
{
+ wxCommandEvent e(EVT_RELEASE_KEYBOARD);
+ e.SetEventObject(this);
+ GetParent()->GetEventHandler()->ProcessEvent(e);
+
if (mBackgroundBitmap)
delete mBackgroundBitmap;
if (mDigitFont)
@@ -806,6 +810,8 @@
return;
}
+ SetFocus();
+
for(i=0; i<GetNumBuiltins(); i++) {
menu.AppendCheckItem(ID_MENU+i, GetBuiltinName(i));
if (mFormatString == GetBuiltinFormat(i))
@@ -840,8 +846,6 @@
Refresh(false);
}
else if (event.RightDown() && mMenuEnabled) {
- SetFocus();
-
wxContextMenuEvent e;
OnContext(e);
}
@@ -896,7 +900,7 @@
return;
default:
- if (keyCode >= '0' || keyCode <= '9')
+ if (keyCode >= '0' && keyCode <= '9')
return;
}
|
| Thread | Author | Date |
|---|---|---|
| [Audacity-cvs] audacity-src/src/widgets TimeTextCtrl.cpp, 1.46, 1.47 | Leland Lucius <llucius@us...> |