Commit 6632d5b4 authored by hjk's avatar hjk
Browse files

Fixes: debugger: less fuss when resizing views

parent db03ceb5
......@@ -67,6 +67,7 @@ void BreakWindow::keyPressEvent(QKeyEvent *ev)
void BreakWindow::resizeEvent(QResizeEvent *ev)
{
/*
QHeaderView *hv = header();
int totalSize = ev->size().width() - 180;
hv->resizeSection(0, 60);
......@@ -75,6 +76,7 @@ void BreakWindow::resizeEvent(QResizeEvent *ev)
hv->resizeSection(3, (totalSize * 30) / 100);
hv->resizeSection(4, 70);
hv->resizeSection(5, 50);
*/
QTreeView::resizeEvent(ev);
}
......
......@@ -65,6 +65,7 @@ StackWindow::StackWindow(QWidget *parent)
void StackWindow::resizeEvent(QResizeEvent *event)
{
/*
QHeaderView *hv = header();
int totalSize = event->size().width() - 120;
......@@ -74,6 +75,7 @@ void StackWindow::resizeEvent(QResizeEvent *event)
hv->resizeSection(2, totalSize / 2);
hv->resizeSection(3, 55);
}
*/
QTreeView::resizeEvent(event);
}
......@@ -136,14 +138,16 @@ void StackWindow::resizeColumnsToContents()
resizeColumnToContents(0);
resizeColumnToContents(1);
resizeColumnToContents(2);
resizeColumnToContents(3);
}
void StackWindow::setAlwaysResizeColumnsToContents(bool on)
{
m_alwaysResizeColumnsToContents = on;
QHeaderView::ResizeMode mode = on
? QHeaderView::ResizeToContents : QHeaderView::Interactive;
QHeaderView::ResizeMode mode =
on ? QHeaderView::ResizeToContents : QHeaderView::Interactive;
header()->setResizeMode(0, mode);
header()->setResizeMode(1, mode);
header()->setResizeMode(2, mode);
header()->setResizeMode(3, mode);
}
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