]> git.lyx.org Git - lyx.git/blobdiff - src/BufferView.cpp
Revert "Objective-C compililation support with cmake and C++11"
[lyx.git] / src / BufferView.cpp
index 2d3df5f8661e3a50eb231952daf874799646112d..ba0df6ef5f8892d51eacb3b7a6d47d6862954299 100644 (file)
@@ -686,6 +686,10 @@ Change const BufferView::getCurrentChange() const
                return Change(Change::UNCHANGED);
 
        DocIterator dit = d->cursor_.selectionBegin();
+       // The selected content might have been changed (see #7685)
+       while (dit.inMathed())
+               // Find enclosing text cursor
+               dit.pop_back();
        return dit.paragraph().lookupChange(dit.pos());
 }
 
@@ -1104,12 +1108,12 @@ bool BufferView::getStatus(FuncRequest const & cmd, FuncStatus & flag)
 
        case LFUN_CHANGES_TRACK:
                flag.setEnabled(true);
-               flag.setOnOff(buffer_.params().trackChanges);
+               flag.setOnOff(buffer_.params().track_changes);
                break;
 
        case LFUN_CHANGES_OUTPUT:
                flag.setEnabled(true);
-               flag.setOnOff(buffer_.params().outputChanges);
+               flag.setOnOff(buffer_.params().output_changes);
                break;
 
        case LFUN_CHANGES_MERGE:
@@ -1426,12 +1430,12 @@ void BufferView::dispatch(FuncRequest const & cmd, DispatchResult & dr)
        }
 
        case LFUN_CHANGES_TRACK:
-               buffer_.params().trackChanges = !buffer_.params().trackChanges;
+               buffer_.params().track_changes = !buffer_.params().track_changes;
                break;
 
        case LFUN_CHANGES_OUTPUT:
-               buffer_.params().outputChanges = !buffer_.params().outputChanges;
-               if (buffer_.params().outputChanges) {
+               buffer_.params().output_changes = !buffer_.params().output_changes;
+               if (buffer_.params().output_changes) {
                        bool dvipost    = LaTeXFeatures::isAvailable("dvipost");
                        bool xcolorulem = LaTeXFeatures::isAvailable("ulem") &&
                                          LaTeXFeatures::isAvailable("xcolor");