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
be5f55e5
Commit
be5f55e5
authored
Aug 16, 2011
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt: use QString iso std::string
parent
084f3f4c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
14 deletions
+12
-14
modules/gui/qt4/components/simple_preferences.cpp
modules/gui/qt4/components/simple_preferences.cpp
+12
-14
No files found.
modules/gui/qt4/components/simple_preferences.cpp
View file @
be5f55e5
...
...
@@ -903,7 +903,6 @@ void SPrefsPanel::configML()
#ifdef WIN32
#include <QDialogButtonBox>
#include "util/registry.hpp"
#include <string>
bool
SPrefsPanel
::
addType
(
const
char
*
psz_ext
,
QTreeWidgetItem
*
current
,
QTreeWidgetItem
*
parent
,
QVLCRegistry
*
qvReg
)
...
...
@@ -1026,8 +1025,8 @@ void SPrefsPanel::assoDialog()
void
addAsso
(
QVLCRegistry
*
qvReg
,
const
char
*
psz_ext
)
{
std
::
s
tring
s_path
(
"VLC"
);
s_path
+=
psz_ext
;
std
::
s
tring
s_path2
=
s_path
;
QS
tring
s_path
(
"VLC"
);
s_path
+=
psz_ext
;
QS
tring
s_path2
=
s_path
;
/* Save a backup if already assigned */
char
*
psz_value
=
qvReg
->
ReadRegistryString
(
psz_ext
,
""
,
""
);
...
...
@@ -1037,27 +1036,26 @@ void addAsso( QVLCRegistry *qvReg, const char *psz_ext )
delete
psz_value
;
/* Put a "link" to VLC.EXT as default */
qvReg
->
WriteRegistryString
(
psz_ext
,
""
,
s_path
.
c_str
(
)
);
qvReg
->
WriteRegistryString
(
psz_ext
,
""
,
qtu
(
s_path
)
);
/* Create the needed Key if they weren't done in the installer */
if
(
!
qvReg
->
RegistryKeyExists
(
s_path
.
c_str
(
)
)
)
if
(
!
qvReg
->
RegistryKeyExists
(
qtu
(
s_path
)
)
)
{
qvReg
->
WriteRegistryString
(
psz_ext
,
""
,
s_path
.
c_str
(
)
);
qvReg
->
WriteRegistryString
(
s_path
.
c_str
(
),
""
,
"Media file"
);
qvReg
->
WriteRegistryString
(
s_path
.
append
(
"
\\
shell"
).
c_str
()
,
""
,
"Play"
);
qvReg
->
WriteRegistryString
(
psz_ext
,
""
,
qtu
(
s_path
)
);
qvReg
->
WriteRegistryString
(
qtu
(
s_path
),
""
,
"Media file"
);
qvReg
->
WriteRegistryString
(
qtu
(
s_path
.
append
(
"
\\
shell"
)
)
,
""
,
"Play"
);
/* Get the installer path */
QVLCRegistry
*
qvReg2
=
new
QVLCRegistry
(
HKEY_LOCAL_MACHINE
);
std
::
string
str_temp
;
str_temp
.
assign
(
qvReg2
->
ReadRegistryString
(
"Software
\\
VideoLAN
\\
VLC"
,
""
,
""
)
);
QString
str_temp
=
qvReg2
->
ReadRegistryString
(
"Software
\\
VideoLAN
\\
VLC"
,
""
,
""
);
if
(
str_temp
.
size
()
)
{
qvReg
->
WriteRegistryString
(
s_path
.
append
(
"
\\
Play
\\
command"
).
c_str
(
),
""
,
str_temp
.
append
(
" --started-from-file
\"
%1
\"
"
).
c_str
(
)
);
qvReg
->
WriteRegistryString
(
qtu
(
s_path
.
append
(
"
\\
Play
\\
command"
)
),
""
,
qtu
(
str_temp
.
append
(
" --started-from-file
\"
%1
\"
"
)
)
);
qvReg
->
WriteRegistryString
(
s_path2
.
append
(
"
\\
DefaultIcon"
).
c_str
(
),
""
,
str_temp
.
append
(
",0"
).
c_str
(
)
);
qvReg
->
WriteRegistryString
(
qtu
(
s_path2
.
append
(
"
\\
DefaultIcon"
)
),
""
,
qtu
(
str_temp
.
append
(
",0"
)
)
);
}
delete
qvReg2
;
}
...
...
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