Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
7cd31167
Commit
7cd31167
authored
Apr 22, 2011
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt, Message dialog: use a nicer update button
Close #4300
parent
6ea360ad
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
14 deletions
+25
-14
modules/gui/qt4/dialogs/messages.cpp
modules/gui/qt4/dialogs/messages.cpp
+14
-6
modules/gui/qt4/dialogs/messages.hpp
modules/gui/qt4/dialogs/messages.hpp
+3
-0
modules/gui/qt4/ui/messages_panel.ui
modules/gui/qt4/ui/messages_panel.ui
+8
-8
No files found.
modules/gui/qt4/dialogs/messages.cpp
View file @
7cd31167
...
...
@@ -26,8 +26,6 @@
#include "dialogs/messages.hpp"
#include <QSpinBox>
#include <QLabel>
#include <QTextEdit>
#include <QTextCursor>
#include <QFileDialog>
...
...
@@ -36,10 +34,8 @@
#include <QTabWidget>
#include <QTreeWidget>
#include <QTreeWidgetItem>
#include <QHeaderView>
#include <QMutex>
#include <QLineEdit>
#include <QPushButton>
#include <QScrollBar>
#include <assert.h>
...
...
@@ -83,7 +79,7 @@ MessagesDialog::MessagesDialog( intf_thread_t *_p_intf)
updateTree
();
/* Modules tree */
ui
.
modulesTree
->
header
()
->
hide
(
);
ui
.
modulesTree
->
setHeaderHidden
(
true
);
/* Buttons and general layout */
ui
.
saveLogButton
->
setToolTip
(
qtr
(
"Saves all the displayed logs to a file"
)
);
...
...
@@ -95,14 +91,21 @@ MessagesDialog::MessagesDialog( intf_thread_t *_p_intf)
"--verbose-objects=+printthatobject,-dontprintthatone
\n
"
"(keyword 'all' to applies to all objects)"
);
updateButton
=
new
QPushButton
(
QIcon
(
":/update"
),
""
);
ui
.
mainTab
->
setCornerWidget
(
updateButton
);
updateButton
->
setVisible
(
false
);
updateButton
->
setFlat
(
true
);
BUTTONACT
(
ui
.
clearButton
,
clear
()
);
BUTTONACT
(
u
i
.
u
pdateButton
,
updateTree
()
);
BUTTONACT
(
updateButton
,
updateTree
()
);
BUTTONACT
(
ui
.
saveLogButton
,
save
()
);
CONNECT
(
ui
.
vbobjectsEdit
,
editingFinished
(),
this
,
updateConfig
());
CONNECT
(
ui
.
bottomButtonsBox
,
rejected
(),
this
,
hide
()
);
CONNECT
(
ui
.
verbosityBox
,
valueChanged
(
int
),
this
,
changeVerbosity
(
int
)
);
CONNECT
(
ui
.
mainTab
,
currentChanged
(
int
),
this
,
tabChanged
(
int
)
);
/* General action */
readSettings
(
"Messages"
,
QSize
(
600
,
450
)
);
...
...
@@ -279,6 +282,11 @@ void MessagesDialog::updateTree()
buildTree
(
NULL
,
VLC_OBJECT
(
p_intf
->
p_libvlc
)
);
}
void
MessagesDialog
::
tabChanged
(
int
i
)
{
updateButton
->
setVisible
(
i
==
1
);
}
static
void
MsgCallback
(
msg_cb_data_t
*
data
,
msg_item_t
*
item
,
unsigned
)
{
int
canc
=
vlc_savecancel
();
...
...
modules/gui/qt4/dialogs/messages.hpp
View file @
7cd31167
...
...
@@ -58,10 +58,13 @@ private slots:
void
changeVerbosity
(
int
);
void
clear
();
void
updateTree
();
void
tabChanged
(
int
);
private:
void
buildTree
(
QTreeWidgetItem
*
,
vlc_object_t
*
);
friend
class
Singleton
<
MessagesDialog
>
;
QPushButton
*
updateButton
;
};
#endif
modules/gui/qt4/ui/messages_panel.ui
View file @
7cd31167
...
...
@@ -72,7 +72,14 @@
</widget>
</item>
<item
row=
"1"
column=
"3"
>
<widget
class=
"QLineEdit"
name=
"vbobjectsEdit"
/>
<widget
class=
"QLineEdit"
name=
"vbobjectsEdit"
>
<property
name=
"minimumSize"
>
<size>
<width>
80
</width>
<height>
0
</height>
</size>
</property>
</widget>
</item>
<item
row=
"1"
column=
"4"
>
<widget
class=
"QPushButton"
name=
"saveLogButton"
>
...
...
@@ -97,13 +104,6 @@
</column>
</widget>
</item>
<item
row=
"1"
column=
"0"
>
<widget
class=
"QPushButton"
name=
"updateButton"
>
<property
name=
"text"
>
<string>
&
Update
</string>
</property>
</widget>
</item>
</layout>
</widget>
</widget>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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