Commit 2216cda2 authored by Thorbjørn Lindeijer's avatar Thorbjørn Lindeijer
Browse files

Fixed the sizehints of the editor or splitters

Done with mae.
parent fca3ec1f
......@@ -140,7 +140,6 @@ struct EditorManagerPrivate {
Internal::SplitterOrView *m_splitter;
QPointer<IEditor> m_currentEditor;
QPointer<SplitterOrView> m_currentView;
QStackedLayout *m_stackedLayout;
ICore *m_core;
......@@ -182,7 +181,6 @@ struct EditorManagerPrivate {
EditorManagerPrivate::EditorManagerPrivate(ICore *core, QWidget *parent) :
m_view(0),
m_splitter(0),
m_stackedLayout(0),
m_core(core),
m_revertToSavedAction(new QAction(EditorManager::tr("Revert to Saved"), parent)),
m_saveAction(new QAction(parent)),
......@@ -388,8 +386,10 @@ EditorManager::EditorManager(ICore *core, QWidget *parent) :
m_d->m_view = m_d->m_splitter->view();
m_d->m_stackedLayout = new QStackedLayout(this);
m_d->m_stackedLayout->addWidget(m_d->m_splitter);
QHBoxLayout *layout = new QHBoxLayout(this);
layout->setMargin(0);
layout->setSpacing(0);
layout->addWidget(m_d->m_splitter);
updateActions();
......@@ -423,11 +423,6 @@ void EditorManager::init()
pluginManager()->addObject(m_d->m_openEditorsFactory);
}
QSize EditorManager::minimumSizeHint() const
{
return QSize(400, 300);
}
QString EditorManager::defaultExternalEditor() const
{
#ifdef Q_OS_MAC
......
......@@ -151,8 +151,6 @@ public:
void saveSettings(QSettings *settings);
void readSettings(QSettings *settings);
QSize minimumSizeHint() const;
Internal::OpenEditorsWindow *windowPopup() const;
void showWindowPopup() const;
......
......@@ -656,6 +656,13 @@ SplitterOrView *SplitterOrView::findNextView_helper(SplitterOrView *view, bool *
return 0;
}
QSize SplitterOrView::minimumSizeHint() const
{
if (m_splitter)
return m_splitter->minimumSizeHint();
return QSize(64, 64);
}
void SplitterOrView::split(Qt::Orientation orientation)
{
Q_ASSERT(m_view && m_splitter == 0);
......
......@@ -179,8 +179,8 @@ public:
SplitterOrView *findNextView(SplitterOrView *view);
QSize sizeHint() const { return QSize(32, 32); }
QSize minimumSizeHint() const { return QSize(32, 32); }
QSize sizeHint() const { return minimumSizeHint(); }
QSize minimumSizeHint() const;
protected:
void focusInEvent(QFocusEvent *);
......
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