Commit c70ccce1 authored by Mike Kremer's avatar Mike Kremer
Browse files

Update logger position after startup so that it's displayed correctly if in in-scene mode.

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@11992 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 15f8f945
...@@ -582,8 +582,6 @@ Core::init() { ...@@ -582,8 +582,6 @@ Core::init() {
coreWidget_->toolSplitter_->restoreState (windowStates.value("Core/ToolSplitter").toByteArray ()); coreWidget_->toolSplitter_->restoreState (windowStates.value("Core/ToolSplitter").toByteArray ());
coreWidget_->splitter_->restoreState (windowStates.value("Core/LogSplitter").toByteArray ()); coreWidget_->splitter_->restoreState (windowStates.value("Core/LogSplitter").toByteArray ());
// Update logger
coreWidget_->showLogger(OpenFlipper::Options::loggerState());
coreWidget_->show(); coreWidget_->show();
applyOptions(); applyOptions();
......
...@@ -126,6 +126,9 @@ void Core::commandLineScript(const char* _filename ) { ...@@ -126,6 +126,9 @@ void Core::commandLineScript(const char* _filename ) {
void Core::slotExecuteAfterStartup() { void Core::slotExecuteAfterStartup() {
// Update logger
coreWidget_->updateInSceneLoggerGeometry();
//check if we have scripting support: //check if we have scripting support:
bool scriptingSupport = false; bool scriptingSupport = false;
slotPluginExists("scripting",scriptingSupport); slotPluginExists("scripting",scriptingSupport);
......
...@@ -473,6 +473,9 @@ public: ...@@ -473,6 +473,9 @@ public:
/// Show logger in splitter or not /// Show logger in splitter or not
void showLoggerInSplitView(bool _show); void showLoggerInSplitView(bool _show);
/// Set in-scene logger geometry right
void updateInSceneLoggerGeometry();
/// Hide or show toolbox area /// Hide or show toolbox area
void toggleToolbox(); void toggleToolbox();
......
...@@ -146,3 +146,12 @@ void CoreWidget::showLoggerInSplitView(bool _show) { ...@@ -146,3 +146,12 @@ void CoreWidget::showLoggerInSplitView(bool _show) {
splitter_->setSizes(wsizes); splitter_->setSizes(wsizes);
} }
} }
//-----------------------------------------------------------------------------
void CoreWidget::updateInSceneLoggerGeometry() {
if(loggerState_ == OpenFlipper::Options::InScene) {
slidingLogger_->updateGeometry();
}
}
...@@ -99,6 +99,9 @@ class DLLEXPORT QtSlideWindow : public QGraphicsProxyWidget ...@@ -99,6 +99,9 @@ class DLLEXPORT QtSlideWindow : public QGraphicsProxyWidget
/// restores the state /// restores the state
void restoreState (QSettings &_settings); void restoreState (QSettings &_settings);
/// Call this to correctly set start and ending positions
void updateParentGeometry();
private: private:
/// paints decoration /// paints decoration
...@@ -134,9 +137,6 @@ class DLLEXPORT QtSlideWindow : public QGraphicsProxyWidget ...@@ -134,9 +137,6 @@ class DLLEXPORT QtSlideWindow : public QGraphicsProxyWidget
/// Slide widget down /// Slide widget down
void slideDown(); void slideDown();
/// Call this to correctly set start and ending positions
void updateParentGeometry();
// Slot is called whenever the animation is finished // Slot is called whenever the animation is finished
void animationFinished(); void animationFinished();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment