mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-25 22:06:15 +00:00
Introduce GuiWorkArea::setFullScreen()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22902 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
1ff60667a6
commit
b409db5d1c
@ -1839,7 +1839,7 @@ void GuiView::lfunUiToggle(FuncRequest const & cmd)
|
||||
}
|
||||
#endif
|
||||
if (arg != "fullscreen") {
|
||||
message(bformat(_("LFUN_UI_TOGGLE %1$s unknown command!"), arg));
|
||||
message(bformat(_("LFUN_UI_TOGGLE %1$s unknown command!"), from_utf8(arg)));
|
||||
return;
|
||||
}
|
||||
|
||||
@ -1850,8 +1850,7 @@ void GuiView::lfunUiToggle(FuncRequest const & cmd)
|
||||
#endif
|
||||
// FIXME: it is not enough to take care of the current work area.
|
||||
// All work areas are affected by a full screen mode!
|
||||
d.current_work_area_->setFrameStyle(QFrame::NoFrame);
|
||||
d.current_work_area_->bufferView().setFullScreen(false);
|
||||
d.current_work_area_->setFullScreen(false);
|
||||
menuBar()->show();
|
||||
statusBar()->show();
|
||||
} else {
|
||||
@ -1859,8 +1858,7 @@ void GuiView::lfunUiToggle(FuncRequest const & cmd)
|
||||
menuBar()->hide();
|
||||
// FIXME: it is not enough to take care of the current work area.
|
||||
// All work areas are affected by a full screen mode!
|
||||
d.current_work_area_->setFrameStyle(QFrame::NoFrame);
|
||||
d.current_work_area_->bufferView().setFullScreen(true);
|
||||
d.current_work_area_->setFullScreen(true);
|
||||
#if QT_VERSION >= 0x040300
|
||||
setContentsMargins(-2, -2, -2, -2);
|
||||
#endif
|
||||
|
@ -257,6 +257,13 @@ void GuiWorkArea::close()
|
||||
}
|
||||
|
||||
|
||||
void GuiWorkArea::setFullScreen(bool full_screen)
|
||||
{
|
||||
setFrameStyle(QFrame::NoFrame);
|
||||
buffer_view_->setFullScreen(full_screen);
|
||||
}
|
||||
|
||||
|
||||
BufferView & GuiWorkArea::bufferView()
|
||||
{
|
||||
return *buffer_view_;
|
||||
|
@ -109,6 +109,8 @@ public:
|
||||
///
|
||||
~GuiWorkArea();
|
||||
|
||||
///
|
||||
void setFullScreen(bool full_screen);
|
||||
///
|
||||
void scheduleRedraw() { schedule_redraw_ = true; }
|
||||
///
|
||||
|
Loading…
Reference in New Issue
Block a user