]> git.lyx.org Git - lyx.git/commitdiff
* GuiView.cpp:
authorJürgen Spitzmüller <spitz@lyx.org>
Sat, 19 Jul 2008 13:17:46 +0000 (13:17 +0000)
committerJürgen Spitzmüller <spitz@lyx.org>
Sat, 19 Jul 2008 13:17:46 +0000 (13:17 +0000)
- disable non-working splitting actions (bug 5044).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25712 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/GuiView.cpp

index 06663b5d02cc6ceb1fa8e1ad63270064b16a1631..ca024a5c36f91080e5c5c0e4b403b6b94113a19a 100644 (file)
@@ -1095,7 +1095,12 @@ bool GuiView::getStatus(FuncRequest const & cmd, FuncStatus & flag)
                break;
 
        case LFUN_SPLIT_VIEW:
-               enable = buf;
+               if (cmd.getArg(0) == "vertical")
+                       enable = buf && (d.splitter_->count() == 1 ||
+                                        d.splitter_->orientation() == Qt::Vertical);
+               else
+                       enable = buf && (d.splitter_->count() == 1 ||
+                                        d.splitter_->orientation() == Qt::Horizontal);
                break;
 
        case LFUN_CLOSE_TAB_GROUP: