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
05f6ff05
Commit
05f6ff05
authored
Jun 10, 2012
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Message dialog: put the clear button in the corner
parent
3023a06e
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
24 deletions
+18
-24
modules/gui/qt4/dialogs/messages.cpp
modules/gui/qt4/dialogs/messages.cpp
+17
-15
modules/gui/qt4/dialogs/messages.hpp
modules/gui/qt4/dialogs/messages.hpp
+1
-2
modules/gui/qt4/ui/messages_panel.ui
modules/gui/qt4/ui/messages_panel.ui
+0
-7
No files found.
modules/gui/qt4/dialogs/messages.cpp
View file @
05f6ff05
...
...
@@ -80,7 +80,6 @@ MessagesDialog::MessagesDialog( intf_thread_t *_p_intf)
ui
.
setupUi
(
this
);
ui
.
bottomButtonsBox
->
addButton
(
new
QPushButton
(
qtr
(
"&Close"
),
this
),
QDialogButtonBox
::
RejectRole
);
updateTree
();
/* Modules tree */
ui
.
modulesTree
->
setHeaderHidden
(
true
);
...
...
@@ -97,13 +96,12 @@ MessagesDialog::MessagesDialog( intf_thread_t *_p_intf)
getSettings
()
->
endGroup
();
updateButton
=
new
QPushButton
(
QIcon
(
":/update"
),
""
);
updateButton
->
setToolTip
(
qtr
(
"Update the tree"
)
);
ui
.
mainTab
->
setCornerWidget
(
updateButton
);
updateButton
->
setVisible
(
false
);
updateButton
->
setFlat
(
true
);
ui
.
mainTab
->
setCornerWidget
(
updateButton
);
tabChanged
(
0
);
BUTTONACT
(
ui
.
clearButton
,
clear
()
);
BUTTONACT
(
updateButton
,
updateTree
()
);
BUTTONACT
(
updateButton
,
updateOrClear
()
);
BUTTONACT
(
ui
.
saveLogButton
,
save
()
);
CONNECT
(
ui
.
filterEdit
,
editingFinished
(),
this
,
updateConfig
()
);
CONNECT
(
ui
.
filterEdit
,
textChanged
(
QString
),
this
,
filterMessages
()
);
...
...
@@ -118,6 +116,8 @@ MessagesDialog::MessagesDialog( intf_thread_t *_p_intf)
/* Hook up to LibVLC messaging */
vlc_Subscribe
(
&
sub
,
MsgCallback
,
this
);
buildTree
(
NULL
,
VLC_OBJECT
(
p_intf
->
p_libvlc
)
);
}
MessagesDialog
::~
MessagesDialog
()
...
...
@@ -235,11 +235,6 @@ void MessagesDialog::customEvent( QEvent *event )
sinkMessage
(
msge
);
}
void
MessagesDialog
::
clear
()
{
ui
.
messages
->
clear
();
}
bool
MessagesDialog
::
save
()
{
QString
saveLogFileName
=
QFileDialog
::
getSaveFileName
(
...
...
@@ -300,15 +295,22 @@ void MessagesDialog::buildTree( QTreeWidgetItem *parentItem,
vlc_list_release
(
l
);
}
void
MessagesDialog
::
update
Tree
()
void
MessagesDialog
::
update
OrClear
()
{
ui
.
modulesTree
->
clear
();
buildTree
(
NULL
,
VLC_OBJECT
(
p_intf
->
p_libvlc
)
);
if
(
ui
.
mainTab
->
currentIndex
()
==
1
)
{
ui
.
modulesTree
->
clear
();
buildTree
(
NULL
,
VLC_OBJECT
(
p_intf
->
p_libvlc
)
);
}
else
ui
.
messages
->
clear
();
}
void
MessagesDialog
::
tabChanged
(
int
i
)
{
updateButton
->
setVisible
(
i
==
1
);
updateButton
->
setIcon
(
i
==
1
?
QIcon
(
":/update"
)
:
QIcon
(
":/toolbar/clear"
)
);
updateButton
->
setToolTip
(
i
==
1
?
qtr
(
"Update the tree"
)
:
qtr
(
"Clear the messages"
)
);
}
void
MessagesDialog
::
MsgCallback
(
void
*
self
,
int
type
,
const
msg_item_t
*
item
,
...
...
modules/gui/qt4/dialogs/messages.hpp
View file @
05f6ff05
...
...
@@ -64,8 +64,7 @@ private slots:
bool
save
();
void
updateConfig
();
void
changeVerbosity
(
int
);
void
clear
();
void
updateTree
();
void
updateOrClear
();
void
tabChanged
(
int
);
void
filterMessages
();
...
...
modules/gui/qt4/ui/messages_panel.ui
View file @
05f6ff05
...
...
@@ -44,13 +44,6 @@
</property>
</widget>
</item>
<item
row=
"1"
column=
"5"
>
<widget
class=
"QPushButton"
name=
"clearButton"
>
<property
name=
"text"
>
<string>
&
Clear
</string>
</property>
</widget>
</item>
<item
row=
"1"
column=
"1"
>
<widget
class=
"QVLCDebugLevelSpinBox"
name=
"verbosityBox"
>
<property
name=
"wrapping"
>
...
...
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