Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Donald Haase
Cockatrice
Commits
c1d295a9
Commit
c1d295a9
authored
Nov 20, 2009
by
Max-Wilhelm Bruker
Browse files
visual improvements
parent
ef46d6e8
Changes
2
Hide whitespace changes
Inline
Side-by-side
cockatrice/src/tab_deck_storage.cpp
View file @
c1d295a9
...
...
@@ -25,27 +25,40 @@ TabDeckStorage::TabDeckStorage(Client *_client)
localDirView
->
setSortingEnabled
(
true
);
localDirView
->
header
()
->
setResizeMode
(
QHeaderView
::
ResizeToContents
);
leftToolBar
=
new
QToolBar
;
leftToolBar
->
setOrientation
(
Qt
::
Horizontal
);
leftToolBar
->
setIconSize
(
QSize
(
32
,
32
));
QHBoxLayout
*
leftToolBarLayout
=
new
QHBoxLayout
;
leftToolBarLayout
->
addStretch
();
leftToolBarLayout
->
addWidget
(
leftToolBar
);
leftToolBarLayout
->
addStretch
();
QVBoxLayout
*
leftVbox
=
new
QVBoxLayout
;
leftVbox
->
addWidget
(
localDirView
);
leftVbox
->
addLayout
(
leftToolBarLayout
);
leftGroupBox
=
new
QGroupBox
;
leftGroupBox
->
setLayout
(
leftVbox
);
toolBar
=
new
QToolBar
;
toolBar
->
setOrientation
(
Qt
::
Vertical
);
toolBar
->
setIconSize
(
QSize
(
24
,
24
));
rightToolBar
=
new
QToolBar
;
rightToolBar
->
setOrientation
(
Qt
::
Horizontal
);
rightToolBar
->
setIconSize
(
QSize
(
32
,
32
));
QHBoxLayout
*
rightToolBarLayout
=
new
QHBoxLayout
;
rightToolBarLayout
->
addStretch
();
rightToolBarLayout
->
addWidget
(
rightToolBar
);
rightToolBarLayout
->
addStretch
();
serverDirView
=
new
QTreeWidget
;
serverDirView
->
header
()
->
setResizeMode
(
QHeaderView
::
ResizeToContents
);
serverDirView
->
setColumnCount
(
3
);
QVBoxLayout
*
rightVbox
=
new
QVBoxLayout
;
rightVbox
->
addWidget
(
serverDirView
);
rightVbox
->
addLayout
(
rightToolBarLayout
);
rightGroupBox
=
new
QGroupBox
;
rightGroupBox
->
setLayout
(
rightVbox
);
QHBoxLayout
*
hbox
=
new
QHBoxLayout
;
hbox
->
addWidget
(
leftGroupBox
);
hbox
->
addWidget
(
toolBar
);
hbox
->
addWidget
(
rightGroupBox
);
aUpload
=
new
QAction
(
this
);
...
...
@@ -55,15 +68,16 @@ TabDeckStorage::TabDeckStorage(Client *_client)
aDownload
->
setIcon
(
QIcon
(
":/resources/arrow_left_green.svg"
));
connect
(
aDownload
,
SIGNAL
(
triggered
()),
this
,
SLOT
(
actDownload
()));
aNewFolder
=
new
QAction
(
this
);
aNewFolder
->
setIcon
(
qApp
->
style
()
->
standardIcon
(
QStyle
::
SP_FileDialogNewFolder
));
connect
(
aNewFolder
,
SIGNAL
(
triggered
()),
this
,
SLOT
(
actNewFolder
()));
aDelete
=
new
QAction
(
this
);
aDelete
->
setIcon
(
QIcon
(
":/resources/remove_row.svg"
));
connect
(
aDelete
,
SIGNAL
(
triggered
()),
this
,
SLOT
(
actDelete
()));
t
oolBar
->
addAction
(
aUpload
);
t
oolBar
->
addAction
(
aDownload
);
t
oolBar
->
addAction
(
aNewFolder
);
t
oolBar
->
addAction
(
aDelete
);
leftT
oolBar
->
addAction
(
aUpload
);
rightT
oolBar
->
addAction
(
aDownload
);
rightT
oolBar
->
addAction
(
aNewFolder
);
rightT
oolBar
->
addAction
(
aDelete
);
retranslateUi
();
setLayout
(
hbox
);
...
...
cockatrice/src/tab_deck_storage.h
View file @
c1d295a9
...
...
@@ -21,7 +21,7 @@ private:
QTreeView
*
localDirView
;
QFileSystemModel
*
localDirModel
;
QSortFilterProxyModel
*
sortFilter
;
QToolBar
*
t
oolBar
;
QToolBar
*
leftToolBar
,
*
rightT
oolBar
;
QTreeWidget
*
serverDirView
;
QGroupBox
*
leftGroupBox
,
*
rightGroupBox
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment