mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-25 10:58:52 +00:00
* src/frontends/Toolbars.h:
* src/frontends/Toolbars.C: rename change_tracking to review * lib/ui/default.ui: remove duplicate "review" toolbar * src/frontends/LyXView.C: implement context-sensitivity for the review toolbar git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15610 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
826c31a80d
commit
9ecf6723bc
@ -38,5 +38,4 @@ Toolbars
|
||||
"table" "table,bottom"
|
||||
"math" "math,bottom"
|
||||
"minibuffer" "off,bottom"
|
||||
"review" "review,top"
|
||||
End
|
||||
|
@ -287,13 +287,15 @@ BufferView * LyXView::view() const
|
||||
|
||||
void LyXView::updateToolbars()
|
||||
{
|
||||
bool const math = work_area_->bufferView().cursor().inMathed();
|
||||
bool const math =
|
||||
work_area_->bufferView().cursor().inMathed();
|
||||
bool const table =
|
||||
lyx::getStatus(FuncRequest(LFUN_LAYOUT_TABULAR)).enabled();
|
||||
// TODO: How should we handle the CT toolbar?
|
||||
bool const change_tracking = true;
|
||||
bool const review =
|
||||
lyx::getStatus(FuncRequest(LFUN_CHANGES_TRACK)).enabled() &&
|
||||
lyx::getStatus(FuncRequest(LFUN_CHANGES_TRACK)).onoff(true);
|
||||
|
||||
toolbars_->update(math, table, change_tracking);
|
||||
toolbars_->update(math, table, review);
|
||||
// update redaonly status of open dialogs. This could also be in
|
||||
// updateMenubar(), but since updateToolbars() and updateMenubar()
|
||||
// are always called together it is only here.
|
||||
|
@ -65,7 +65,7 @@ void Toolbars::display(string const & name, bool show)
|
||||
}
|
||||
|
||||
|
||||
void Toolbars::update(bool in_math, bool in_table, bool change_tracking)
|
||||
void Toolbars::update(bool in_math, bool in_table, bool review)
|
||||
{
|
||||
update();
|
||||
|
||||
@ -79,7 +79,7 @@ void Toolbars::update(bool in_math, bool in_table, bool change_tracking)
|
||||
else if (cit->flags & ToolbarBackend::TABLE)
|
||||
displayToolbar(*cit, in_table);
|
||||
else if (cit->flags & ToolbarBackend::REVIEW)
|
||||
displayToolbar(*cit, change_tracking);
|
||||
displayToolbar(*cit, review);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -84,7 +84,7 @@ public:
|
||||
void display(std::string const & name, bool show);
|
||||
|
||||
/// Update the state of the toolbars.
|
||||
void update(bool in_math, bool in_table, bool change_tracking);
|
||||
void update(bool in_math, bool in_table, bool review);
|
||||
|
||||
/// Select the right layout in the combox.
|
||||
void setLayout(std::string const & layout);
|
||||
|
Loading…
Reference in New Issue
Block a user