Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
9f516fa2
Commit
9f516fa2
authored
Oct 11, 2005
by
Damien Fouilleul
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vlccontrol.cpp: fixed a bug in setVariable where arguments for VariantChangeType were inverted
parent
1fbd377c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
activex/vlccontrol.cpp
activex/vlccontrol.cpp
+5
-5
No files found.
activex/vlccontrol.cpp
View file @
9f516fa2
...
@@ -345,20 +345,20 @@ STDMETHODIMP VLCControl::setVariable(BSTR name, VARIANT value)
...
@@ -345,20 +345,20 @@ STDMETHODIMP VLCControl::setVariable(BSTR name, VARIANT value)
switch
(
i_type
)
switch
(
i_type
)
{
{
case
VLC_VAR_BOOL
:
case
VLC_VAR_BOOL
:
hr
=
VariantChangeType
(
&
value
,
&
arg
,
0
,
VT_BOOL
);
hr
=
VariantChangeType
(
&
arg
,
&
value
,
0
,
VT_BOOL
);
if
(
SUCCEEDED
(
hr
)
)
if
(
SUCCEEDED
(
hr
)
)
val
.
b_bool
=
(
VARIANT_TRUE
==
V_BOOL
(
&
arg
))
?
VLC_TRUE
:
VLC_FALSE
;
val
.
b_bool
=
(
VARIANT_TRUE
==
V_BOOL
(
&
arg
))
?
VLC_TRUE
:
VLC_FALSE
;
break
;
break
;
case
VLC_VAR_INTEGER
:
case
VLC_VAR_INTEGER
:
case
VLC_VAR_HOTKEY
:
case
VLC_VAR_HOTKEY
:
hr
=
VariantChangeType
(
&
value
,
&
arg
,
0
,
VT_I4
);
hr
=
VariantChangeType
(
&
arg
,
&
value
,
0
,
VT_I4
);
if
(
SUCCEEDED
(
hr
)
)
if
(
SUCCEEDED
(
hr
)
)
val
.
i_int
=
V_I4
(
&
arg
);
val
.
i_int
=
V_I4
(
&
arg
);
break
;
break
;
case
VLC_VAR_FLOAT
:
case
VLC_VAR_FLOAT
:
hr
=
VariantChangeType
(
&
value
,
&
arg
,
0
,
VT_R4
);
hr
=
VariantChangeType
(
&
arg
,
&
value
,
0
,
VT_R4
);
if
(
SUCCEEDED
(
hr
)
)
if
(
SUCCEEDED
(
hr
)
)
val
.
f_float
=
V_R4
(
&
arg
);
val
.
f_float
=
V_R4
(
&
arg
);
break
;
break
;
...
@@ -368,7 +368,7 @@ STDMETHODIMP VLCControl::setVariable(BSTR name, VARIANT value)
...
@@ -368,7 +368,7 @@ STDMETHODIMP VLCControl::setVariable(BSTR name, VARIANT value)
case
VLC_VAR_FILE
:
case
VLC_VAR_FILE
:
case
VLC_VAR_DIRECTORY
:
case
VLC_VAR_DIRECTORY
:
case
VLC_VAR_VARIABLE
:
case
VLC_VAR_VARIABLE
:
hr
=
VariantChangeType
(
&
value
,
&
arg
,
0
,
VT_BSTR
);
hr
=
VariantChangeType
(
&
arg
,
&
value
,
0
,
VT_BSTR
);
if
(
SUCCEEDED
(
hr
)
)
if
(
SUCCEEDED
(
hr
)
)
{
{
val
.
psz_string
=
CStrFromBSTR
(
codePage
,
V_BSTR
(
&
arg
));
val
.
psz_string
=
CStrFromBSTR
(
codePage
,
V_BSTR
(
&
arg
));
...
@@ -378,7 +378,7 @@ STDMETHODIMP VLCControl::setVariable(BSTR name, VARIANT value)
...
@@ -378,7 +378,7 @@ STDMETHODIMP VLCControl::setVariable(BSTR name, VARIANT value)
case
VLC_VAR_TIME
:
case
VLC_VAR_TIME
:
// use a double value to represent time (base is expressed in seconds)
// use a double value to represent time (base is expressed in seconds)
hr
=
VariantChangeType
(
&
value
,
&
arg
,
0
,
VT_R8
);
hr
=
VariantChangeType
(
&
arg
,
&
value
,
0
,
VT_R8
);
if
(
SUCCEEDED
(
hr
)
)
if
(
SUCCEEDED
(
hr
)
)
val
.
i_time
=
(
signed
__int64
)(
V_R8
(
&
arg
)
*
1000000.0
);
val
.
i_time
=
(
signed
__int64
)(
V_R8
(
&
arg
)
*
1000000.0
);
break
;
break
;
...
...
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