@@ -42,22 +42,25 @@ HandlesView::HandlesView(QWidget* parent) : QWidget(parent)
42
42
this ->setLayout (mVertLayout );
43
43
44
44
// Create the action list for the right click context menu
45
- mActionRefresh = new QAction (QIcon (" :/images/arrow_restart .png" ), tr (" &Refresh" ), this );
45
+ mActionRefresh = new QAction (QIcon (" :/icons/ images/arrow-restart .png" ), tr (" &Refresh" ), this );
46
46
connect (mActionRefresh , SIGNAL (triggered ()), this , SLOT (reloadData ()));
47
- mActionCloseHandle = new QAction (QIcon (" :/images/close-all-tabs.png" ), tr (" Close handle" ), this );
47
+ addAction (mActionRefresh );
48
+ mActionCloseHandle = new QAction (QIcon (" :/icons/images/close-all-tabs.png" ), tr (" Close handle" ), this );
48
49
connect (mActionCloseHandle , SIGNAL (triggered ()), this , SLOT (closeHandleSlot ()));
49
- mActionDisablePrivilege = new QAction (QIcon (" :/images/close-all-tabs.png" ), tr (" Disable Privilege: " ), this );
50
+ mActionDisablePrivilege = new QAction (QIcon (" :/icons/ images/close-all-tabs.png" ), tr (" Disable Privilege: " ), this );
50
51
connect (mActionDisablePrivilege , SIGNAL (triggered ()), this , SLOT (disablePrivilegeSlot ()));
51
52
mActionEnablePrivilege = new QAction (tr (" Enable Privilege: " ), this );
52
53
connect (mActionEnablePrivilege , SIGNAL (triggered ()), this , SLOT (enablePrivilegeSlot ()));
53
- mActionDisableAllPrivileges = new QAction (QIcon (" :/images/close-all-tabs.png" ), tr (" Disable all privileges" ), this );
54
+ mActionDisableAllPrivileges = new QAction (QIcon (" :/icons/ images/close-all-tabs.png" ), tr (" Disable all privileges" ), this );
54
55
connect (mActionDisableAllPrivileges , SIGNAL (triggered ()), this , SLOT (disableAllPrivilegesSlot ()));
55
56
mActionEnableAllPrivileges = new QAction (tr (" Enable all privileges" ), this );
56
57
connect (mActionEnableAllPrivileges , SIGNAL (triggered ()), this , SLOT (enableAllPrivilegesSlot ()));
57
58
58
59
connect (mHandlesTable , SIGNAL (contextMenuSignal (const QPoint &)), this , SLOT (handlesTableContextMenuSlot (const QPoint &)));
59
60
connect (mTcpConnectionsTable , SIGNAL (contextMenuSignal (const QPoint &)), this , SLOT (tcpConnectionsTableContextMenuSlot (const QPoint &)));
60
61
connect (mPrivilegesTable , SIGNAL (contextMenuSignal (const QPoint &)), this , SLOT (privilegesTableContextMenuSlot (const QPoint &)));
62
+ connect (Config (), SIGNAL (shortcutsUpdated ()), this , SLOT (refreshShortcuts ()));
63
+ connect (Bridge::getBridge (), SIGNAL (dbgStateChanged (DBGSTATE)), this , SLOT (dbgStateChanged (DBGSTATE)));
61
64
62
65
if (!IsWindowsVistaOrGreater ())
63
66
{
@@ -66,6 +69,7 @@ HandlesView::HandlesView(QWidget* parent) : QWidget(parent)
66
69
mTcpConnectionsTable ->reloadData ();
67
70
}
68
71
reloadData ();
72
+ refreshShortcuts ();
69
73
}
70
74
71
75
void HandlesView::reloadData ()
@@ -76,6 +80,26 @@ void HandlesView::reloadData()
76
80
enumTcpConnections ();
77
81
enumPrivileges ();
78
82
}
83
+ else
84
+ {
85
+ mHandlesTable ->setRowCount (0 );
86
+ mHandlesTable ->reloadData ();
87
+ mTcpConnectionsTable ->setRowCount (0 );
88
+ mTcpConnectionsTable ->reloadData ();
89
+ mPrivilegesTable ->setRowCount (0 );
90
+ mPrivilegesTable ->reloadData ();
91
+ }
92
+ }
93
+
94
+ void HandlesView::refreshShortcuts ()
95
+ {
96
+ mActionRefresh ->setShortcut (ConfigShortcut (" ActionRefresh" ));
97
+ }
98
+
99
+ void HandlesView::dbgStateChanged (DBGSTATE state)
100
+ {
101
+ if (state == stopped)
102
+ reloadData ();
79
103
}
80
104
81
105
void HandlesView::handlesTableContextMenuSlot (const QPoint & pos)
0 commit comments