Commit aac4be4e authored by Christoffer Ackelman's avatar Christoffer Ackelman Committed by Esteban Blanc

QT: Change the 'View all toplevel' menu button in the workbench to a checkbox.

parent 69c2b407
......@@ -1294,13 +1294,8 @@ void WttQtWidget::activate_twowindows()
wtt->activate_twowindows();
}
void WttQtWidget::activate_set_alltoplevel()
void WttQtWidget::activate_set_alltoplevel(bool set)
{
int set = ((int)((WttQt*)wtt)->view_alltoplevel_w->isChecked());
if (sender() != ((WttQt*)wtt)->view_alltoplevel_w) {
set = !set;
((WttQt*)wtt)->view_alltoplevel_w->setChecked(set);
}
wtt->activate_set_alltoplevel(set);
}
......@@ -2057,8 +2052,8 @@ WttQt::WttQt(void* wt_parent_ctx, const char* wt_name, const char* iconname,
"$pwr_exe/xtt_zoom_reset.png");
addMenuItem(
toplevel, view, "T&wo Windows", SLOT(activate_twowindows()), "CTRL+T");
view_alltoplevel_w = addMenuItem(
toplevel, view, "V&iew all toplevel", SLOT(activate_set_alltoplevel()));
view_alltoplevel_w = addCheckableMenuItem(
toplevel, view, "V&iew all toplevel", SLOT(activate_set_alltoplevel(bool)));
addMenuItem(toplevel, view, "&Messages", SLOT(activate_messages()));
// Options menu
......
......@@ -287,7 +287,7 @@ public slots:
void activate_zoom_out();
void activate_zoom_reset();
void activate_twowindows();
void activate_set_alltoplevel();
void activate_set_alltoplevel(bool set);
void activate_messages();
void activate_view();
void activate_savesettings();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment