Merge
This commit is contained in:
@@ -85,9 +85,15 @@ int main(int argc, char **argv)
|
||||
argv1_ = argv[1];
|
||||
else
|
||||
argv1_ = "";
|
||||
|
||||
argv0 = Glib::filename_to_utf8 (argv0_);
|
||||
argv1 = Glib::filename_to_utf8 (argv1_);
|
||||
|
||||
#ifdef GLIBMM_EXCEPTIONS_ENABLED
|
||||
argv0 = Glib::filename_to_utf8 (argv0);
|
||||
argv1 = Glib::filename_to_utf8 (argv1);
|
||||
#else
|
||||
std::auto_ptr<Glib::Error> error;
|
||||
argv0 = Glib::filename_to_utf8 (argv0_, error);
|
||||
argv1 = Glib::filename_to_utf8 (argv1_, error);
|
||||
#endif //GLIBMM_EXCEPTIONS_ENABLED
|
||||
|
||||
Glib::thread_init();
|
||||
gdk_threads_init();
|
||||
|
@@ -1018,8 +1018,8 @@ void Preferences::savePressed () {
|
||||
void Preferences::okPressed () {
|
||||
|
||||
storePreferences ();
|
||||
options.copyFrom (&moptions);
|
||||
workflowUpdate();
|
||||
options.copyFrom (&moptions);
|
||||
hide ();
|
||||
}
|
||||
|
||||
@@ -1120,10 +1120,15 @@ void Preferences::switchThemeTo(Glib::ustring newTheme) {
|
||||
|
||||
void Preferences::workflowUpdate (){
|
||||
|
||||
if(moptions.tabbedUI)
|
||||
parent->epanel->hide_all();
|
||||
else
|
||||
parent->epanel->show_all();
|
||||
if(moptions.tabbedUI != options.tabbedUI)
|
||||
{
|
||||
parent->MoveFileBrowserToMain();
|
||||
parent->SetMainCurrent();
|
||||
if(moptions.tabbedUI)
|
||||
parent->epanel->hide_all();
|
||||
else
|
||||
parent->epanel->show_all();
|
||||
}
|
||||
}
|
||||
|
||||
void Preferences::switchFontTo(Glib::ustring newFont) {
|
||||
|
@@ -324,16 +324,33 @@ void RTWindow::SetEditorCurrent()
|
||||
mainNB->set_current_page (mainNB->page_num (*epanel));
|
||||
}
|
||||
|
||||
void RTWindow::SetMainCurrent()
|
||||
{
|
||||
mainNB->set_current_page (mainNB->page_num (*fpanel));
|
||||
}
|
||||
|
||||
void RTWindow::MoveFileBrowserToMain()
|
||||
{
|
||||
FileCatalog *fCatalog = fpanel->fileCatalog;
|
||||
epanel->catalogPane->remove(*fCatalog);
|
||||
fpanel->ribbonPane->add(*fCatalog);
|
||||
fCatalog->fileBrowser->setArrangement(ThumbBrowserBase::TB_Vertical);
|
||||
fCatalog->redrawAll();
|
||||
}
|
||||
|
||||
void RTWindow::MoveFileBrowserToEditor()
|
||||
{
|
||||
FileCatalog *fCatalog = fpanel->fileCatalog;
|
||||
fpanel->ribbonPane->remove(*fCatalog);
|
||||
epanel->catalogPane->add(*fCatalog);
|
||||
fCatalog->fileBrowser->setArrangement(ThumbBrowserBase::TB_Horizontal);
|
||||
fCatalog->redrawAll();
|
||||
}
|
||||
|
||||
bool RTWindow::on_expose_event_epanel(GdkEventExpose* event)
|
||||
{
|
||||
|
||||
if(!options.tabbedUI && epanel->catalogPane->get_children().size() ==0 ){
|
||||
FileCatalog *fCatalog = fpanel->fileCatalog;
|
||||
fpanel->ribbonPane->remove(*fCatalog);
|
||||
epanel->catalogPane->add(*fCatalog);
|
||||
fCatalog->fileBrowser->setArrangement(ThumbBrowserBase::TB_Horizontal);
|
||||
fCatalog->redrawAll();
|
||||
}
|
||||
if(!options.tabbedUI && epanel->catalogPane->get_children().size() ==0 )
|
||||
MoveFileBrowserToEditor();
|
||||
return false; // Gtk::VBox::on_expose_event(event);
|
||||
}
|
||||
|
||||
@@ -341,13 +358,7 @@ bool RTWindow::on_expose_event_epanel(GdkEventExpose* event)
|
||||
bool RTWindow::on_expose_event_fpanel(GdkEventExpose* event)
|
||||
{
|
||||
|
||||
if(!options.tabbedUI && fpanel->ribbonPane->get_children().size() ==0 ){
|
||||
FileCatalog *fCatalog = fpanel->fileCatalog;
|
||||
epanel->catalogPane->remove(*fCatalog);
|
||||
//dirpaned->pack2(*fileCatalog,true,true);
|
||||
fpanel->ribbonPane->add(*fCatalog);
|
||||
fCatalog->fileBrowser->setArrangement(ThumbBrowserBase::TB_Vertical);
|
||||
fCatalog->redrawAll();
|
||||
}
|
||||
if(!options.tabbedUI && fpanel->ribbonPane->get_children().size() ==0 )
|
||||
MoveFileBrowserToMain();
|
||||
return false; // Gtk::HPaned::on_expose_event(event);
|
||||
}
|
@@ -67,6 +67,9 @@ class RTWindow : public Gtk::Window, public rtengine::ProgressListener{
|
||||
rtengine::ProgressListener* getProgressListener () { return pldBridge; }
|
||||
EditorPanel* epanel;
|
||||
void SetEditorCurrent();
|
||||
void SetMainCurrent();
|
||||
void MoveFileBrowserToEditor();
|
||||
void MoveFileBrowserToMain();
|
||||
};
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user