Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
3e7d9284
Commit
3e7d9284
authored
Oct 28, 2007
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt4 - yeah, redefining some existing options *IS* a good idea..
parent
b1262408
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
47 additions
and
24 deletions
+47
-24
modules/gui/qt4/components/open.cpp
modules/gui/qt4/components/open.cpp
+45
-18
modules/gui/qt4/components/open.hpp
modules/gui/qt4/components/open.hpp
+2
-0
modules/gui/qt4/qt4.cpp
modules/gui/qt4/qt4.cpp
+0
-6
No files found.
modules/gui/qt4/components/open.cpp
View file @
3e7d9284
...
@@ -98,7 +98,6 @@ FileOpenPanel::FileOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
...
@@ -98,7 +98,6 @@ FileOpenPanel::FileOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
// FIXME
// FIXME
lineFileEdit
=
dialogBox
->
findChildren
<
QLineEdit
*>
()[
1
];
lineFileEdit
=
dialogBox
->
findChildren
<
QLineEdit
*>
()[
1
];
#endif
#endif
/* Make a list of QLabel inside the QFileDialog to access the good ones */
/* Make a list of QLabel inside the QFileDialog to access the good ones */
QList
<
QLabel
*>
listLabel
=
dialogBox
->
findChildren
<
QLabel
*>
();
QList
<
QLabel
*>
listLabel
=
dialogBox
->
findChildren
<
QLabel
*>
();
...
@@ -229,7 +228,15 @@ DiscOpenPanel::DiscOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
...
@@ -229,7 +228,15 @@ DiscOpenPanel::DiscOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
{
{
ui
.
setupUi
(
this
);
ui
.
setupUi
(
this
);
char
*
psz_discpath
=
config_GetPsz
(
p_intf
,
"qt-discdialog-path"
);
/* Get the default configuration path for the devices */
psz_dvddiscpath
=
config_GetPsz
(
p_intf
,
"dvd"
);
psz_vcddiscpath
=
config_GetPsz
(
p_intf
,
"vcd"
);
psz_cddadiscpath
=
config_GetPsz
(
p_intf
,
"cd-audio"
);
/* State to avoid overwritting the users changes with the configuration */
b_firstdvd
=
true
;
b_firstvcd
=
true
;
b_firstcdda
=
true
;
#if WIN32
/* Disc drives probing for Windows */
#if WIN32
/* Disc drives probing for Windows */
char
szDrives
[
512
];
char
szDrives
[
512
];
...
@@ -248,16 +255,8 @@ DiscOpenPanel::DiscOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
...
@@ -248,16 +255,8 @@ DiscOpenPanel::DiscOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
}
}
SetErrorMode
(
oldMode
);
SetErrorMode
(
oldMode
);
}
}
int
index
=
ui
.
deviceCombo
->
findText
(
qfu
(
psz_discpath
)
);
if
(
index
!=
-
1
)
ui
.
deviceCombo
->
setCurrentIndex
(
index
);
#endif
/* Disc Probing under Windows */
#endif
/* Disc Probing under Windows */
ui
.
deviceCombo
->
setEditText
(
qfu
(
psz_discpath
)
);
delete
psz_discpath
;
/* CONNECTs */
/* CONNECTs */
BUTTONACT
(
ui
.
dvdRadioButton
,
updateButtons
()
);
BUTTONACT
(
ui
.
dvdRadioButton
,
updateButtons
()
);
BUTTONACT
(
ui
.
vcdRadioButton
,
updateButtons
()
);
BUTTONACT
(
ui
.
vcdRadioButton
,
updateButtons
()
);
...
@@ -270,21 +269,44 @@ DiscOpenPanel::DiscOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
...
@@ -270,21 +269,44 @@ DiscOpenPanel::DiscOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
CONNECT
(
ui
.
chapterSpin
,
valueChanged
(
int
),
this
,
updateMRL
());
CONNECT
(
ui
.
chapterSpin
,
valueChanged
(
int
),
this
,
updateMRL
());
CONNECT
(
ui
.
audioSpin
,
valueChanged
(
int
),
this
,
updateMRL
());
CONNECT
(
ui
.
audioSpin
,
valueChanged
(
int
),
this
,
updateMRL
());
CONNECT
(
ui
.
subtitlesSpin
,
valueChanged
(
int
),
this
,
updateMRL
());
CONNECT
(
ui
.
subtitlesSpin
,
valueChanged
(
int
),
this
,
updateMRL
());
updateButtons
();
}
}
DiscOpenPanel
::~
DiscOpenPanel
()
DiscOpenPanel
::~
DiscOpenPanel
()
{}
{
delete
psz_dvddiscpath
;
delete
psz_vcddiscpath
;
delete
psz_cddadiscpath
;
}
void
DiscOpenPanel
::
clear
()
void
DiscOpenPanel
::
clear
()
{
{
ui
.
titleSpin
->
setValue
(
0
);
ui
.
titleSpin
->
setValue
(
0
);
ui
.
chapterSpin
->
setValue
(
0
);
ui
.
chapterSpin
->
setValue
(
0
);
b_firstcdda
=
true
;
b_firstdvd
=
true
;
b_firstvcd
=
true
;
}
}
#ifdef WIN32
#define setDrive( psz_name ) {\
int index = ui.deviceCombo->findText( qfu( psz_name ) ); \
if( index != -1 ) ui.deviceCombo->setCurrentIndex( index );}
#else
#define setDrive( psz_name ) {\
ui.deviceCombo->setEditText( qfu( psz_name ) ); }
#endif
void
DiscOpenPanel
::
updateButtons
()
void
DiscOpenPanel
::
updateButtons
()
{
{
if
(
ui
.
dvdRadioButton
->
isChecked
()
)
if
(
ui
.
dvdRadioButton
->
isChecked
()
)
{
{
if
(
b_firstdvd
)
{
setDrive
(
psz_dvddiscpath
);
b_firstdvd
=
false
;
}
ui
.
titleLabel
->
setText
(
qtr
(
"Title"
)
);
ui
.
titleLabel
->
setText
(
qtr
(
"Title"
)
);
ui
.
chapterLabel
->
show
();
ui
.
chapterLabel
->
show
();
ui
.
chapterSpin
->
show
();
ui
.
chapterSpin
->
show
();
...
@@ -292,13 +314,23 @@ void DiscOpenPanel::updateButtons()
...
@@ -292,13 +314,23 @@ void DiscOpenPanel::updateButtons()
}
}
else
if
(
ui
.
vcdRadioButton
->
isChecked
()
)
else
if
(
ui
.
vcdRadioButton
->
isChecked
()
)
{
{
if
(
b_firstvcd
)
{
setDrive
(
psz_vcddiscpath
);
b_firstvcd
=
false
;
}
ui
.
titleLabel
->
setText
(
qtr
(
"Entry"
)
);
ui
.
titleLabel
->
setText
(
qtr
(
"Entry"
)
);
ui
.
chapterLabel
->
hide
();
ui
.
chapterLabel
->
hide
();
ui
.
chapterSpin
->
hide
();
ui
.
chapterSpin
->
hide
();
ui
.
diskOptionBox_2
->
show
();
ui
.
diskOptionBox_2
->
show
();
}
}
else
else
/* CDDA */
{
{
if
(
b_firstcdda
)
{
setDrive
(
psz_cddadiscpath
);
b_firstcdda
=
false
;
}
ui
.
titleLabel
->
setText
(
qtr
(
"Track"
)
);
ui
.
titleLabel
->
setText
(
qtr
(
"Track"
)
);
ui
.
chapterLabel
->
hide
();
ui
.
chapterLabel
->
hide
();
ui
.
chapterSpin
->
hide
();
ui
.
chapterSpin
->
hide
();
...
@@ -308,7 +340,6 @@ void DiscOpenPanel::updateButtons()
...
@@ -308,7 +340,6 @@ void DiscOpenPanel::updateButtons()
updateMRL
();
updateMRL
();
}
}
void
DiscOpenPanel
::
updateMRL
()
void
DiscOpenPanel
::
updateMRL
()
{
{
QString
mrl
=
""
;
QString
mrl
=
""
;
...
@@ -372,11 +403,7 @@ void DiscOpenPanel::browseDevice()
...
@@ -372,11 +403,7 @@ void DiscOpenPanel::browseDevice()
}
}
void
DiscOpenPanel
::
accept
()
void
DiscOpenPanel
::
accept
()
{
{}
/* set dialog box current directory as last known path */
config_PutPsz
(
p_intf
,
"qt-discdialog-path"
,
qtu
(
ui
.
deviceCombo
->
currentText
()
)
);
}
/**************************************************************************
/**************************************************************************
* Open Network streams and URL pages *
* Open Network streams and URL pages *
...
...
modules/gui/qt4/components/open.hpp
View file @
3e7d9284
...
@@ -137,6 +137,8 @@ public:
...
@@ -137,6 +137,8 @@ public:
virtual
void
accept
()
;
virtual
void
accept
()
;
private:
private:
Ui
::
OpenDisk
ui
;
Ui
::
OpenDisk
ui
;
char
*
psz_dvddiscpath
,
*
psz_vcddiscpath
,
*
psz_cddadiscpath
;
bool
b_firstdvd
,
b_firstvcd
,
b_firstcdda
;
public
slots
:
public
slots
:
virtual
void
updateMRL
()
;
virtual
void
updateMRL
()
;
virtual
void
updateButtons
()
;
virtual
void
updateButtons
()
;
...
...
modules/gui/qt4/qt4.cpp
View file @
3e7d9284
...
@@ -72,8 +72,6 @@ static void ShowDialog ( intf_thread_t *, int, int, intf_dialog_args_t * );
...
@@ -72,8 +72,6 @@ static void ShowDialog ( intf_thread_t *, int, int, intf_dialog_args_t * );
#define FILEDIALOG_PATH_TEXT N_("Path to use in openfile dialog")
#define FILEDIALOG_PATH_TEXT N_("Path to use in openfile dialog")
#define DISCDIALOG_PATH_TEXT N_("Path to device to use in open disc dialog")
#define NOTIFICATION_TEXT N_("Show notification popup on track change")
#define NOTIFICATION_TEXT N_("Show notification popup on track change")
#define NOTIFICATION_LONGTEXT N_( \
#define NOTIFICATION_LONGTEXT N_( \
"Show a notification popup with the artist and track name when " \
"Show a notification popup with the artist and track name when " \
...
@@ -127,10 +125,6 @@ vlc_module_begin();
...
@@ -127,10 +125,6 @@ vlc_module_begin();
FILEDIALOG_PATH_TEXT
,
VLC_TRUE
);
FILEDIALOG_PATH_TEXT
,
VLC_TRUE
);
change_autosave
();
change_autosave
();
change_internal
();
change_internal
();
add_string
(
"qt-discdialog-path"
,
NULL
,
NULL
,
DISCDIALOG_PATH_TEXT
,
DISCDIALOG_PATH_TEXT
,
VLC_TRUE
);
change_autosave
();
change_internal
();
add_bool
(
"qt-notification"
,
VLC_TRUE
,
NULL
,
NOTIFICATION_TEXT
,
add_bool
(
"qt-notification"
,
VLC_TRUE
,
NULL
,
NOTIFICATION_TEXT
,
NOTIFICATION_LONGTEXT
,
VLC_FALSE
);
NOTIFICATION_LONGTEXT
,
VLC_FALSE
);
...
...
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