summaryrefslogtreecommitdiff
path: root/src/gui/windows/mailwindow.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-04-30 16:07:15 +0300
committerAndrei Karas <akaras@inbox.ru>2015-04-30 16:07:15 +0300
commita5d4a43d93f1acc5b0fabe98e45bffb1bcbe34b3 (patch)
treeae132e8a16b45775f3dcaa68326d8ec3646dcfe7 /src/gui/windows/mailwindow.cpp
parent2dbc66a47f39e8212898af88832afa0522e893b5 (diff)
downloadplus-a5d4a43d93f1acc5b0fabe98e45bffb1bcbe34b3.tar.gz
plus-a5d4a43d93f1acc5b0fabe98e45bffb1bcbe34b3.tar.bz2
plus-a5d4a43d93f1acc5b0fabe98e45bffb1bcbe34b3.tar.xz
plus-a5d4a43d93f1acc5b0fabe98e45bffb1bcbe34b3.zip
Use scrollarea for mail list.
Diffstat (limited to 'src/gui/windows/mailwindow.cpp')
-rw-r--r--src/gui/windows/mailwindow.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/gui/windows/mailwindow.cpp b/src/gui/windows/mailwindow.cpp
index aec30ce89..b23984c4c 100644
--- a/src/gui/windows/mailwindow.cpp
+++ b/src/gui/windows/mailwindow.cpp
@@ -36,6 +36,7 @@
#include "gui/widgets/label.h"
#include "gui/widgets/layout.h"
#include "gui/widgets/layouttype.h"
+#include "gui/widgets/scrollarea.h"
#include "utils/delete2.h"
#include "utils/dtor.h"
@@ -54,6 +55,8 @@ MailWindow::MailWindow() :
mMessagesMap(),
mMailModel(new ExtendedNamesModel),
mListBox(new ExtendedListBox(this, mMailModel, "extendedlistbox.xml")),
+ mListScrollArea(new ScrollArea(this, mListBox,
+ getOptionBool("showlistbackground"), "mail_listbackground.xml")),
// TRANSLATORS: mail window button
mRefreshButton(new Button(this, _("Refresh"), "refresh", this)),
// TRANSLATORS: mail window button
@@ -81,10 +84,12 @@ MailWindow::MailWindow() :
setMinHeight(179);
center();
+ mListScrollArea->setHorizontalScrollPolicy(ScrollArea::SHOW_NEVER);
+
ContainerPlacer placer;
placer = getPlacer(0, 0);
- placer(0, 0, mListBox, 4, 4).setPadding(3);
+ placer(0, 0, mListScrollArea, 4, 5).setPadding(3);
placer(4, 0, mRefreshButton);
placer(4, 1, mOpenButton);
placer(4, 2, mNewButton);