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
19acda05
Commit
19acda05
authored
May 14, 2011
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt: kill warnings and probably a crash on Win32
parent
146af0bd
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
14 deletions
+10
-14
modules/gui/qt4/components/simple_preferences.cpp
modules/gui/qt4/components/simple_preferences.cpp
+4
-4
modules/gui/qt4/util/registry.cpp
modules/gui/qt4/util/registry.cpp
+5
-9
modules/gui/qt4/util/registry.hpp
modules/gui/qt4/util/registry.hpp
+1
-1
No files found.
modules/gui/qt4/components/simple_preferences.cpp
View file @
19acda05
...
@@ -966,7 +966,7 @@ void SPrefsPanel::assoDialog()
...
@@ -966,7 +966,7 @@ void SPrefsPanel::assoDialog()
videoType
->
setExpanded
(
true
);
videoType
->
setCheckState
(
0
,
Qt
::
Unchecked
);
videoType
->
setExpanded
(
true
);
videoType
->
setCheckState
(
0
,
Qt
::
Unchecked
);
otherType
->
setExpanded
(
true
);
otherType
->
setCheckState
(
0
,
Qt
::
Unchecked
);
otherType
->
setExpanded
(
true
);
otherType
->
setCheckState
(
0
,
Qt
::
Unchecked
);
QTreeWidgetItem
*
currentItem
;
QTreeWidgetItem
*
currentItem
=
NULL
;
int
i_temp
=
0
;
int
i_temp
=
0
;
#define aTa( name ) i_temp += addType( name, currentItem, audioType, qvReg )
#define aTa( name ) i_temp += addType( name, currentItem, audioType, qvReg )
...
@@ -1081,7 +1081,7 @@ void delAsso( QVLCRegistry *qvReg, const char *psz_ext )
...
@@ -1081,7 +1081,7 @@ void delAsso( QVLCRegistry *qvReg, const char *psz_ext )
}
}
void
SPrefsPanel
::
saveAsso
()
void
SPrefsPanel
::
saveAsso
()
{
{
QVLCRegistry
*
qvReg
;
QVLCRegistry
*
qvReg
=
NULL
;
for
(
int
i
=
0
;
i
<
listAsso
.
size
();
i
++
)
for
(
int
i
=
0
;
i
<
listAsso
.
size
();
i
++
)
{
{
qvReg
=
new
QVLCRegistry
(
HKEY_CLASSES_ROOT
);
qvReg
=
new
QVLCRegistry
(
HKEY_CLASSES_ROOT
);
...
...
modules/gui/qt4/util/registry.cpp
View file @
19acda05
...
@@ -128,10 +128,12 @@ int QVLCRegistry::ReadRegistryInt( const char *path, const char *valueName, int
...
@@ -128,10 +128,12 @@ int QVLCRegistry::ReadRegistryInt( const char *path, const char *valueName, int
return
default_value
;
return
default_value
;
}
}
char
*
QVLCRegistry
::
ReadRegistryString
(
const
char
*
path
,
const
char
*
valueName
,
char
*
default_value
)
char
*
QVLCRegistry
::
ReadRegistryString
(
const
char
*
path
,
const
char
*
valueName
,
c
onst
c
har
*
default_value
)
{
{
HKEY
keyHandle
;
HKEY
keyHandle
;
char
*
tempValue
=
NULL
;
char
*
tempValue
=
NULL
;
char
*
tempValue2
=
NULL
;
DWORD
size1
;
DWORD
size1
;
DWORD
valueType
;
DWORD
valueType
;
...
@@ -145,20 +147,14 @@ char * QVLCRegistry::ReadRegistryString( const char *path, const char *valueName
...
@@ -145,20 +147,14 @@ char * QVLCRegistry::ReadRegistryString( const char *path, const char *valueName
tempValue
=
(
char
*
)
malloc
(
size1
+
1
);
// +1 für NullByte`?
tempValue
=
(
char
*
)
malloc
(
size1
+
1
);
// +1 für NullByte`?
if
(
RegQueryValueEx
(
keyHandle
,
valueName
,
NULL
,
&
valueType
,
(
LPBYTE
)
tempValue
,
&
size1
)
==
ERROR_SUCCESS
)
if
(
RegQueryValueEx
(
keyHandle
,
valueName
,
NULL
,
&
valueType
,
(
LPBYTE
)
tempValue
,
&
size1
)
==
ERROR_SUCCESS
)
{
{
default_value
=
tempValue
;
tempValue2
=
tempValue
;
};
};
}
}
}
}
RegCloseKey
(
keyHandle
);
RegCloseKey
(
keyHandle
);
}
}
if
(
tempValue
==
NULL
)
{
// wenn tempValue nicht aus registry gelesen wurde dafür sorgen das ein neuer String mit der Kopie von DefaultValue
// geliefert wird - das macht das Handling des Rückgabewertes der Funktion einfacher - immer schön mit free freigeben!
default_value
=
strdup
(
default_value
);
}
return
default_value
;
return
tempValue
==
NULL
?
strdup
(
default_value
)
:
tempValue2
;
}
}
double
QVLCRegistry
::
ReadRegistryDouble
(
const
char
*
path
,
const
char
*
valueName
,
double
default_value
)
double
QVLCRegistry
::
ReadRegistryDouble
(
const
char
*
path
,
const
char
*
valueName
,
double
default_value
)
...
...
modules/gui/qt4/util/registry.hpp
View file @
19acda05
...
@@ -39,7 +39,7 @@ public:
...
@@ -39,7 +39,7 @@ public:
void
WriteRegistryDouble
(
const
char
*
path
,
const
char
*
valueName
,
double
value
);
void
WriteRegistryDouble
(
const
char
*
path
,
const
char
*
valueName
,
double
value
);
int
ReadRegistryInt
(
const
char
*
path
,
const
char
*
valueName
,
int
default_value
);
int
ReadRegistryInt
(
const
char
*
path
,
const
char
*
valueName
,
int
default_value
);
char
*
ReadRegistryString
(
const
char
*
path
,
const
char
*
valueName
,
char
*
default_value
);
char
*
ReadRegistryString
(
const
char
*
path
,
const
char
*
valueName
,
c
onst
c
har
*
default_value
);
double
ReadRegistryDouble
(
const
char
*
path
,
const
char
*
valueName
,
double
default_value
);
double
ReadRegistryDouble
(
const
char
*
path
,
const
char
*
valueName
,
double
default_value
);
bool
RegistryKeyExists
(
const
char
*
path
);
bool
RegistryKeyExists
(
const
char
*
path
);
...
...
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