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
905e5d8a
Commit
905e5d8a
authored
Apr 16, 2007
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt4 - Open Dialog. Use #defines for tab naming to avoid miscomprehensions. Cosmectics.
parent
d998d106
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
32 additions
and
26 deletions
+32
-26
modules/gui/qt4/components/open.cpp
modules/gui/qt4/components/open.cpp
+4
-4
modules/gui/qt4/components/open.hpp
modules/gui/qt4/components/open.hpp
+3
-3
modules/gui/qt4/dialogs/open.cpp
modules/gui/qt4/dialogs/open.cpp
+15
-13
modules/gui/qt4/dialogs/open.hpp
modules/gui/qt4/dialogs/open.hpp
+1
-1
modules/gui/qt4/dialogs_provider.cpp
modules/gui/qt4/dialogs_provider.cpp
+5
-5
modules/gui/qt4/dialogs_provider.hpp
modules/gui/qt4/dialogs_provider.hpp
+4
-0
No files found.
modules/gui/qt4/components/open.cpp
View file @
905e5d8a
...
@@ -216,7 +216,7 @@ void FileOpenPanel::toggleSubtitleFrame()
...
@@ -216,7 +216,7 @@ void FileOpenPanel::toggleSubtitleFrame()
/**************************************************************************
/**************************************************************************
* Disk open
* Disk open
**************************************************************************/
**************************************************************************/
Dis
kOpenPanel
::
Disk
OpenPanel
(
QWidget
*
_parent
,
intf_thread_t
*
_p_intf
)
:
Dis
cOpenPanel
::
Disc
OpenPanel
(
QWidget
*
_parent
,
intf_thread_t
*
_p_intf
)
:
OpenPanel
(
_parent
,
_p_intf
)
OpenPanel
(
_parent
,
_p_intf
)
{
{
ui
.
setupUi
(
this
);
ui
.
setupUi
(
this
);
...
@@ -230,16 +230,16 @@ DiskOpenPanel::DiskOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
...
@@ -230,16 +230,16 @@ DiskOpenPanel::DiskOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
CONNECT
(
ui
.
chapterSpin
,
valueChanged
(
int
),
this
,
updateMRL
());
CONNECT
(
ui
.
chapterSpin
,
valueChanged
(
int
),
this
,
updateMRL
());
}
}
Dis
kOpenPanel
::~
Disk
OpenPanel
()
Dis
cOpenPanel
::~
Disc
OpenPanel
()
{}
{}
void
Dis
k
OpenPanel
::
clear
()
void
Dis
c
OpenPanel
::
clear
()
{
{
ui
.
titleSpin
->
setValue
(
0
);
ui
.
titleSpin
->
setValue
(
0
);
ui
.
chapterSpin
->
setValue
(
0
);
ui
.
chapterSpin
->
setValue
(
0
);
}
}
void
Dis
k
OpenPanel
::
updateMRL
()
void
Dis
c
OpenPanel
::
updateMRL
()
{
{
QString
mrl
=
""
;
QString
mrl
=
""
;
/* DVD */
/* DVD */
...
...
modules/gui/qt4/components/open.hpp
View file @
905e5d8a
...
@@ -103,12 +103,12 @@ private slots:
...
@@ -103,12 +103,12 @@ private slots:
void
updateAddress
();
void
updateAddress
();
};
};
class
Dis
k
OpenPanel
:
public
OpenPanel
class
Dis
c
OpenPanel
:
public
OpenPanel
{
{
Q_OBJECT
;
Q_OBJECT
;
public:
public:
Dis
k
OpenPanel
(
QWidget
*
,
intf_thread_t
*
);
Dis
c
OpenPanel
(
QWidget
*
,
intf_thread_t
*
);
virtual
~
Dis
k
OpenPanel
();
virtual
~
Dis
c
OpenPanel
();
virtual
void
clear
()
;
virtual
void
clear
()
;
private:
private:
Ui
::
OpenDisk
ui
;
Ui
::
OpenDisk
ui
;
...
...
modules/gui/qt4/dialogs/open.cpp
View file @
905e5d8a
...
@@ -48,30 +48,32 @@ OpenDialog::OpenDialog( QWidget *parent, intf_thread_t *_p_intf, bool modal,
...
@@ -48,30 +48,32 @@ OpenDialog::OpenDialog( QWidget *parent, intf_thread_t *_p_intf, bool modal,
resize
(
500
,
300
);
resize
(
500
,
300
);
/* Tab definition and creation */
/* Tab definition and creation */
fileOpenPanel
=
new
FileOpenPanel
(
ui
.
Tab
,
p_intf
);
fileOpenPanel
=
new
FileOpenPanel
(
ui
.
Tab
,
p_intf
);
dis
kOpenPanel
=
new
DiskOpenPanel
(
ui
.
Tab
,
p_intf
);
dis
cOpenPanel
=
new
DiscOpenPanel
(
ui
.
Tab
,
p_intf
);
netOpenPanel
=
new
NetOpenPanel
(
ui
.
Tab
,
p_intf
);
netOpenPanel
=
new
NetOpenPanel
(
ui
.
Tab
,
p_intf
);
captureOpenPanel
=
new
CaptureOpenPanel
(
ui
.
Tab
,
p_intf
);
captureOpenPanel
=
new
CaptureOpenPanel
(
ui
.
Tab
,
p_intf
);
ui
.
Tab
->
addTab
(
fileOpenPanel
,
qtr
(
"&File"
)
);
ui
.
Tab
->
insertTab
(
OPEN_FILE_TAB
,
fileOpenPanel
,
qtr
(
"&File"
)
);
ui
.
Tab
->
addTab
(
diskOpenPanel
,
qtr
(
"&Disc"
)
);
ui
.
Tab
->
insertTab
(
OPEN_DISC_TAB
,
discOpenPanel
,
qtr
(
"&Disc"
)
);
ui
.
Tab
->
addTab
(
netOpenPanel
,
qtr
(
"&Network"
)
);
ui
.
Tab
->
insertTab
(
OPEN_NETWORK_TAB
,
netOpenPanel
,
qtr
(
"&Network"
)
);
ui
.
Tab
->
addTab
(
captureOpenPanel
,
qtr
(
"Capture &Device"
)
);
ui
.
Tab
->
insertTab
(
OPEN_CAPTURE_TAB
,
captureOpenPanel
,
qtr
(
"Capture &Device"
)
);
/* Hide the advancedPanel */
/* Hide the advancedPanel */
ui
.
advancedFrame
->
hide
();
ui
.
advancedFrame
->
hide
();
/* Buttons Creation */
/* Buttons Creation */
QSizePolicy
buttonSizePolicy
(
static_cast
<
QSizePolicy
::
Policy
>
(
7
),
static_cast
<
QSizePolicy
::
Policy
>
(
1
));
QSizePolicy
buttonSizePolicy
(
static_cast
<
QSizePolicy
::
Policy
>
(
7
),
static_cast
<
QSizePolicy
::
Policy
>
(
1
)
);
buttonSizePolicy
.
setHorizontalStretch
(
0
);
buttonSizePolicy
.
setHorizontalStretch
(
0
);
buttonSizePolicy
.
setVerticalStretch
(
0
);
buttonSizePolicy
.
setVerticalStretch
(
0
);
playButton
=
new
QToolButton
();
playButton
=
new
QToolButton
();
playButton
->
setText
(
qtr
(
"&Play"
)
);
playButton
->
setText
(
qtr
(
"&Play"
)
);
playButton
->
setSizePolicy
(
buttonSizePolicy
);
playButton
->
setSizePolicy
(
buttonSizePolicy
);
playButton
->
setMinimumSize
(
QSize
(
90
,
0
)
);
playButton
->
setMinimumSize
(
QSize
(
90
,
0
)
);
playButton
->
setPopupMode
(
QToolButton
::
MenuButtonPopup
);
playButton
->
setPopupMode
(
QToolButton
::
MenuButtonPopup
);
playButton
->
setToolButtonStyle
(
Qt
::
ToolButtonTextOnly
);
playButton
->
setToolButtonStyle
(
Qt
::
ToolButtonTextOnly
);
cancelButton
=
new
QToolButton
();
cancelButton
=
new
QToolButton
();
cancelButton
->
setText
(
qtr
(
"&Cancel"
)
);
cancelButton
->
setText
(
qtr
(
"&Cancel"
)
);
...
@@ -96,7 +98,7 @@ OpenDialog::OpenDialog( QWidget *parent, intf_thread_t *_p_intf, bool modal,
...
@@ -96,7 +98,7 @@ OpenDialog::OpenDialog( QWidget *parent, intf_thread_t *_p_intf, bool modal,
CONNECT
(
fileOpenPanel
,
mrlUpdated
(
QString
),
this
,
updateMRL
(
QString
)
);
CONNECT
(
fileOpenPanel
,
mrlUpdated
(
QString
),
this
,
updateMRL
(
QString
)
);
CONNECT
(
netOpenPanel
,
mrlUpdated
(
QString
),
this
,
updateMRL
(
QString
)
);
CONNECT
(
netOpenPanel
,
mrlUpdated
(
QString
),
this
,
updateMRL
(
QString
)
);
CONNECT
(
dis
k
OpenPanel
,
mrlUpdated
(
QString
),
this
,
updateMRL
(
QString
)
);
CONNECT
(
dis
c
OpenPanel
,
mrlUpdated
(
QString
),
this
,
updateMRL
(
QString
)
);
CONNECT
(
captureOpenPanel
,
mrlUpdated
(
QString
),
this
,
CONNECT
(
captureOpenPanel
,
mrlUpdated
(
QString
),
this
,
updateMRL
(
QString
)
);
updateMRL
(
QString
)
);
...
@@ -104,7 +106,7 @@ OpenDialog::OpenDialog( QWidget *parent, intf_thread_t *_p_intf, bool modal,
...
@@ -104,7 +106,7 @@ OpenDialog::OpenDialog( QWidget *parent, intf_thread_t *_p_intf, bool modal,
this
,
newMethod
(
QString
)
);
this
,
newMethod
(
QString
)
);
CONNECT
(
netOpenPanel
,
methodChanged
(
QString
),
CONNECT
(
netOpenPanel
,
methodChanged
(
QString
),
this
,
newMethod
(
QString
)
);
this
,
newMethod
(
QString
)
);
CONNECT
(
dis
k
OpenPanel
,
methodChanged
(
QString
),
CONNECT
(
dis
c
OpenPanel
,
methodChanged
(
QString
),
this
,
newMethod
(
QString
)
);
this
,
newMethod
(
QString
)
);
CONNECT
(
ui
.
slaveText
,
textChanged
(
QString
),
this
,
updateMRL
());
CONNECT
(
ui
.
slaveText
,
textChanged
(
QString
),
this
,
updateMRL
());
...
...
modules/gui/qt4/dialogs/open.hpp
View file @
905e5d8a
...
@@ -72,7 +72,7 @@ private:
...
@@ -72,7 +72,7 @@ private:
Ui
::
Open
ui
;
Ui
::
Open
ui
;
FileOpenPanel
*
fileOpenPanel
;
FileOpenPanel
*
fileOpenPanel
;
NetOpenPanel
*
netOpenPanel
;
NetOpenPanel
*
netOpenPanel
;
Dis
kOpenPanel
*
disk
OpenPanel
;
Dis
cOpenPanel
*
disc
OpenPanel
;
CaptureOpenPanel
*
captureOpenPanel
;
CaptureOpenPanel
*
captureOpenPanel
;
QString
storedMethod
;
QString
storedMethod
;
...
...
modules/gui/qt4/dialogs_provider.cpp
View file @
905e5d8a
...
@@ -177,23 +177,23 @@ void DialogsProvider::bookmarksDialog()
...
@@ -177,23 +177,23 @@ void DialogsProvider::bookmarksDialog()
void
DialogsProvider
::
openDialog
()
void
DialogsProvider
::
openDialog
()
{
{
openDialog
(
0
);
openDialog
(
OPEN_FILE_TAB
);
}
}
void
DialogsProvider
::
openFileDialog
()
void
DialogsProvider
::
openFileDialog
()
{
{
openDialog
(
0
);
openDialog
(
OPEN_FILE_TAB
);
}
}
void
DialogsProvider
::
openDiscDialog
()
void
DialogsProvider
::
openDiscDialog
()
{
{
openDialog
(
1
);
openDialog
(
OPEN_DISC_TAB
);
}
}
void
DialogsProvider
::
openNetDialog
()
void
DialogsProvider
::
openNetDialog
()
{
{
openDialog
(
2
);
openDialog
(
OPEN_NETWORK_TAB
);
}
}
void
DialogsProvider
::
openCaptureDialog
()
void
DialogsProvider
::
openCaptureDialog
()
{
{
openDialog
(
3
);
openDialog
(
OPEN_CAPTURE_TAB
);
}
}
void
DialogsProvider
::
openDialog
(
int
i_tab
)
void
DialogsProvider
::
openDialog
(
int
i_tab
)
{
{
...
...
modules/gui/qt4/dialogs_provider.hpp
View file @
905e5d8a
...
@@ -68,6 +68,10 @@
...
@@ -68,6 +68,10 @@
string += _("All Files"); \
string += _("All Files"); \
string += " (*.*)";
string += " (*.*)";
#define OPEN_FILE_TAB 0x0
#define OPEN_DISC_TAB 0x1
#define OPEN_NETWORK_TAB 0x2
#define OPEN_CAPTURE_TAB 0x3
class
QEvent
;
class
QEvent
;
class
QSignalMapper
;
class
QSignalMapper
;
...
...
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