Move AddSeparator to VisualTool::SetToolbar

This commit is contained in:
wangqr 2020-05-06 21:20:53 -04:00
parent 7ac2983c61
commit 47b2bfd544
3 changed files with 2 additions and 1 deletions

View file

@ -429,7 +429,6 @@ void VideoDisplay::SetTool(std::unique_ptr<VisualToolBase> new_tool) {
// Hide the tool bar first to eliminate unecessary size changes // Hide the tool bar first to eliminate unecessary size changes
toolBar->Show(false); toolBar->Show(false);
toolBar->ClearTools(); toolBar->ClearTools();
toolBar->AddSeparator();
tool->SetToolbar(toolBar); tool->SetToolbar(toolBar);
// Update size as the new typesetting tool may have changed the subtoolbar size // Update size as the new typesetting tool may have changed the subtoolbar size

View file

@ -58,6 +58,7 @@ VisualToolDrag::VisualToolDrag(VideoDisplay *parent, agi::Context *context)
void VisualToolDrag::SetToolbar(wxToolBar *tb) { void VisualToolDrag::SetToolbar(wxToolBar *tb) {
toolbar = tb; toolbar = tb;
toolbar->AddSeparator();
toolbar->AddTool(-1, _("Toggle between \\move and \\pos"), ICON(visual_move_conv_move)); toolbar->AddTool(-1, _("Toggle between \\move and \\pos"), ICON(visual_move_conv_move));
toolbar->Realize(); toolbar->Realize();
toolbar->Show(true); toolbar->Show(true);

View file

@ -52,6 +52,7 @@ VisualToolVectorClip::VisualToolVectorClip(VideoDisplay *parent, agi::Context *c
void VisualToolVectorClip::SetToolbar(wxToolBar *toolBar) { void VisualToolVectorClip::SetToolbar(wxToolBar *toolBar) {
this->toolBar = toolBar; this->toolBar = toolBar;
toolBar->AddSeparator();
#ifdef __WXMSW__ #ifdef __WXMSW__
int icon_size = toolBar->FromDIP(16); int icon_size = toolBar->FromDIP(16);
#else #else