In MEOW mode size of toolpanel has to depend on size of MEOW window instead on size of main rt window
This commit is contained in:
@@ -453,7 +453,7 @@ public:
|
|||||||
};
|
};
|
||||||
|
|
||||||
EditorPanel::EditorPanel (FilePanel* filePanel)
|
EditorPanel::EditorPanel (FilePanel* filePanel)
|
||||||
: catalogPane(nullptr), realized(false), tbBeforeLock(nullptr), iHistoryShow(nullptr), iHistoryHide(nullptr), iTopPanel_1_Show(nullptr), iTopPanel_1_Hide(nullptr), iRightPanel_1_Show(nullptr), iRightPanel_1_Hide(nullptr), iBeforeLockON(nullptr), iBeforeLockOFF(nullptr), previewHandler(nullptr), beforePreviewHandler(nullptr), beforeIarea(nullptr), beforeBox(nullptr), afterBox(nullptr), beforeLabel(nullptr), afterLabel(nullptr), beforeHeaderBox(nullptr), afterHeaderBox(nullptr), parent(nullptr), openThm(nullptr), isrc(nullptr), ipc(nullptr), beforeIpc(nullptr), err(0), isProcessing(false)
|
: catalogPane(nullptr), realized(false), tbBeforeLock(nullptr), iHistoryShow(nullptr), iHistoryHide(nullptr), iTopPanel_1_Show(nullptr), iTopPanel_1_Hide(nullptr), iRightPanel_1_Show(nullptr), iRightPanel_1_Hide(nullptr), iBeforeLockON(nullptr), iBeforeLockOFF(nullptr), previewHandler(nullptr), beforePreviewHandler(nullptr), beforeIarea(nullptr), beforeBox(nullptr), afterBox(nullptr), beforeLabel(nullptr), afterLabel(nullptr), beforeHeaderBox(nullptr), afterHeaderBox(nullptr), parent(nullptr), parentWindow(nullptr), openThm(nullptr), isrc(nullptr), ipc(nullptr), beforeIpc(nullptr), err(0), isProcessing(false)
|
||||||
{
|
{
|
||||||
|
|
||||||
epih = new EditorPanelIdleHelper;
|
epih = new EditorPanelIdleHelper;
|
||||||
@@ -899,7 +899,7 @@ void EditorPanel::rightPaneButtonReleased (GdkEventButton *event)
|
|||||||
{
|
{
|
||||||
if (event->button == 1) {
|
if (event->button == 1) {
|
||||||
int winW, winH;
|
int winW, winH;
|
||||||
parent->get_size (winW, winH);
|
parentWindow->get_size (winW, winH);
|
||||||
// Button 1 released : it's a resize
|
// Button 1 released : it's a resize
|
||||||
options.toolPanelWidth = winW - hpanedr->get_position();
|
options.toolPanelWidth = winW - hpanedr->get_position();
|
||||||
}
|
}
|
||||||
@@ -929,7 +929,7 @@ void EditorPanel::showTopPanel (bool show)
|
|||||||
void EditorPanel::setAspect ()
|
void EditorPanel::setAspect ()
|
||||||
{
|
{
|
||||||
int winW, winH;
|
int winW, winH;
|
||||||
parent->get_size (winW, winH);
|
parentWindow->get_size (winW, winH);
|
||||||
hpanedl->set_position (options.historyPanelWidth);
|
hpanedl->set_position (options.historyPanelWidth);
|
||||||
hpanedr->set_position (winW - options.toolPanelWidth);
|
hpanedr->set_position (winW - options.toolPanelWidth);
|
||||||
|
|
||||||
|
@@ -67,6 +67,12 @@ public:
|
|||||||
{
|
{
|
||||||
parent = p;
|
parent = p;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void setParentWindow (Gtk::Window* p)
|
||||||
|
{
|
||||||
|
parentWindow = p;
|
||||||
|
}
|
||||||
|
|
||||||
void writeOptions();
|
void writeOptions();
|
||||||
|
|
||||||
void showTopPanel (bool show);
|
void showTopPanel (bool show);
|
||||||
@@ -196,6 +202,7 @@ private:
|
|||||||
HistogramPanel* histogramPanel;
|
HistogramPanel* histogramPanel;
|
||||||
ToolPanelCoordinator* tpc;
|
ToolPanelCoordinator* tpc;
|
||||||
RTWindow* parent;
|
RTWindow* parent;
|
||||||
|
Gtk::Window* parentWindow;
|
||||||
//SaveAsDialog* saveAsDialog;
|
//SaveAsDialog* saveAsDialog;
|
||||||
FilePanel* fPanel;
|
FilePanel* fPanel;
|
||||||
|
|
||||||
|
@@ -124,6 +124,7 @@ void EditWindow::on_mainNB_switch_page(Gtk::Widget* widget, guint page_num)
|
|||||||
void EditWindow::addEditorPanel (EditorPanel* ep, const std::string &name)
|
void EditWindow::addEditorPanel (EditorPanel* ep, const std::string &name)
|
||||||
{
|
{
|
||||||
ep->setParent (parent);
|
ep->setParent (parent);
|
||||||
|
ep->setParentWindow(this);
|
||||||
|
|
||||||
// construct closeable tab for the image
|
// construct closeable tab for the image
|
||||||
Gtk::HBox* hb = Gtk::manage (new Gtk::HBox ());
|
Gtk::HBox* hb = Gtk::manage (new Gtk::HBox ());
|
||||||
|
@@ -146,6 +146,7 @@ RTWindow::RTWindow ()
|
|||||||
if(simpleEditor) {
|
if(simpleEditor) {
|
||||||
epanel = Gtk::manage( new EditorPanel (nullptr) );
|
epanel = Gtk::manage( new EditorPanel (nullptr) );
|
||||||
epanel->setParent (this);
|
epanel->setParent (this);
|
||||||
|
epanel->setParentWindow(this);
|
||||||
add (*epanel);
|
add (*epanel);
|
||||||
show_all ();
|
show_all ();
|
||||||
|
|
||||||
@@ -387,6 +388,7 @@ void RTWindow::addEditorPanel (EditorPanel* ep, const std::string &name)
|
|||||||
wndEdit->addEditorPanel(ep, name);
|
wndEdit->addEditorPanel(ep, name);
|
||||||
} else {
|
} else {
|
||||||
ep->setParent (this);
|
ep->setParent (this);
|
||||||
|
ep->setParentWindow(this);
|
||||||
|
|
||||||
// construct closeable tab for the image
|
// construct closeable tab for the image
|
||||||
Gtk::Grid* titleGrid = Gtk::manage (new Gtk::Grid ());
|
Gtk::Grid* titleGrid = Gtk::manage (new Gtk::Grid ());
|
||||||
@@ -868,6 +870,7 @@ void RTWindow::createSetmEditor()
|
|||||||
// Editor panel, single-tab mode only
|
// Editor panel, single-tab mode only
|
||||||
epanel = Gtk::manage ( new EditorPanel (fpanel) );
|
epanel = Gtk::manage ( new EditorPanel (fpanel) );
|
||||||
epanel->setParent (this);
|
epanel->setParent (this);
|
||||||
|
epanel->setParentWindow(this);
|
||||||
|
|
||||||
// decorate tab
|
// decorate tab
|
||||||
Gtk::Grid* const editorLabelGrid = Gtk::manage (new Gtk::Grid ());
|
Gtk::Grid* const editorLabelGrid = Gtk::manage (new Gtk::Grid ());
|
||||||
|
Reference in New Issue
Block a user