summaryrefslogtreecommitdiff
path: root/core/settings/button/remapdlg.cpp
Side-by-side diff
Diffstat (limited to 'core/settings/button/remapdlg.cpp') (more/less context) (show whitespace changes)
-rw-r--r--core/settings/button/remapdlg.cpp27
1 files changed, 20 insertions, 7 deletions
diff --git a/core/settings/button/remapdlg.cpp b/core/settings/button/remapdlg.cpp
index 511d0e7..a251bd4 100644
--- a/core/settings/button/remapdlg.cpp
+++ b/core/settings/button/remapdlg.cpp
@@ -3,2 +3,3 @@
#include <qcombobox.h>
+#include <qtimer.h>
@@ -49,2 +50,7 @@ RemapDlg::RemapDlg ( const Opie::ODeviceButton *b, bool hold, QWidget *parent, c
+ m_current = 0;
+
+ static const char * const def_channels [] = { "QPE/Application/", "QPE/Launcher", "QPE/System", "QPE/TaskBar", "QPE/", 0 };
+ w_channel-> insertStrList ((const char **) def_channels );
+
m_msg = hold ? b-> heldAction ( ) : b-> pressedAction ( );
@@ -61,4 +67,3 @@ RemapDlg::RemapDlg ( const Opie::ODeviceButton *b, bool hold, QWidget *parent, c
- it = new NoSortItem ( w_list, 4, tr( "Show" ));
- ButtonUtils::inst ( )-> insertAppLnks ( it );
+ m_map_show = new NoSortItem ( w_list, 4, tr( "Show" ));
@@ -67,7 +72,3 @@ RemapDlg::RemapDlg ( const Opie::ODeviceButton *b, bool hold, QWidget *parent, c
- static const char * const def_channels [] = {
- "QPE/Application/", "QPE/Launcher", "QPE/System", "QPE/TaskBar", "QPE/", 0
- };
-
- w_channel-> insertStrList ((const char **) def_channels );
+ QTimer::singleShot ( 0, this, SLOT( delayedInit ( )));
}
@@ -78,2 +79,14 @@ RemapDlg::~RemapDlg ( )
+void RemapDlg::delayedInit ( )
+{
+ bool b = w_list-> viewport ( )-> isUpdatesEnabled ( );
+ w_list-> viewport ( )-> setUpdatesEnabled ( false );
+
+ ButtonUtils::inst ( )-> insertAppLnks ( m_map_show );
+
+ w_list-> viewport ( )-> setUpdatesEnabled ( b );
+
+ m_map_show-> repaint ( );
+}
+
void RemapDlg::itemChanged ( QListViewItem *it )