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
1f1820bc
Commit
1f1820bc
authored
Aug 25, 2005
by
Christophe Massiot
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* modules/gui/wxwidgets: Fix charset when getting file names from the
filesystem.
parent
3740e6a3
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
33 additions
and
19 deletions
+33
-19
modules/gui/wxwidgets/dialogs.cpp
modules/gui/wxwidgets/dialogs.cpp
+9
-7
modules/gui/wxwidgets/open.cpp
modules/gui/wxwidgets/open.cpp
+16
-8
modules/gui/wxwidgets/updatevlc.cpp
modules/gui/wxwidgets/updatevlc.cpp
+5
-3
modules/gui/wxwidgets/wizard.cpp
modules/gui/wxwidgets/wizard.cpp
+3
-1
No files found.
modules/gui/wxwidgets/dialogs.cpp
View file @
1f1820bc
...
...
@@ -402,15 +402,17 @@ void DialogsProvider::OnOpenFileSimple( wxCommandEvent& event )
p_file_dialog
->
GetPaths
(
paths
);
for
(
size_t
i
=
0
;
i
<
paths
.
GetCount
();
i
++
)
{
char
*
psz_utf8
=
FromLocale
(
paths
[
i
].
mb_str
()
);
if
(
event
.
GetInt
()
)
playlist_Add
(
p_playlist
,
(
const
char
*
)
paths
[
i
].
mb_str
(),
(
const
char
*
)
paths
[
i
].
mb_str
(),
playlist_Add
(
p_playlist
,
psz_utf8
,
psz_utf8
,
PLAYLIST_APPEND
|
(
i
?
0
:
PLAYLIST_GO
),
PLAYLIST_END
);
else
playlist_Add
(
p_playlist
,
(
const
char
*
)
paths
[
i
].
mb_str
(),
(
const
char
*
)
paths
[
i
].
mb_str
(),
playlist_Add
(
p_playlist
,
psz_utf8
,
psz_utf8
,
PLAYLIST_APPEND
,
PLAYLIST_END
);
LocaleFree
(
psz_utf8
);
}
}
vlc_object_release
(
p_playlist
);
...
...
@@ -432,11 +434,11 @@ void DialogsProvider::OnOpenDirectory( wxCommandEvent& event )
if
(
p_dir_dialog
&&
p_dir_dialog
->
ShowModal
()
==
wxID_OK
)
{
wxString
path
=
p_dir_dialog
->
GetPath
();
playlist_Add
(
p_playlist
,
(
const
char
*
)
path
.
mb_str
(),
(
const
char
*
)
path
.
mb_str
(),
char
*
psz_utf8
=
FromLocale
(
path
.
mb_str
()
);
playlist_Add
(
p_playlist
,
psz_utf8
,
psz_utf8
,
PLAYLIST_APPEND
|
(
event
.
GetInt
()
?
PLAYLIST_GO
:
0
),
PLAYLIST_END
);
LocaleFree
(
psz_utf8
);
}
vlc_object_release
(
p_playlist
);
...
...
modules/gui/wxwidgets/open.cpp
View file @
1f1820bc
...
...
@@ -1117,15 +1117,20 @@ void OpenDialog::OnOk( wxCommandEvent& WXUNUSED(event) )
for
(
int
i
=
0
;
i
<
(
int
)
mrl
.
GetCount
();
i
++
)
{
vlc_bool_t
b_start
=
!
i
&&
i_open_arg
;
playlist_item_t
*
p_item
=
playlist_ItemNew
(
p_intf
,
(
const
char
*
)
mrl
[
i
].
mb_str
(),
(
const
char
*
)
mrl
[
i
].
mb_str
()
);
playlist_item_t
*
p_item
;
char
*
psz_utf8
;
psz_utf8
=
FromLocale
(
mrl
[
i
].
mb_str
()
);
p_item
=
playlist_ItemNew
(
p_intf
,
psz_utf8
,
psz_utf8
);
LocaleFree
(
psz_utf8
);
/* Insert options */
while
(
i
+
1
<
(
int
)
mrl
.
GetCount
()
&&
((
const
char
*
)
mrl
[
i
+
1
].
mb_str
())[
0
]
==
':'
)
{
playlist_ItemAddOption
(
p_item
,
mrl
[
i
+
1
].
mb_str
()
);
psz_utf8
=
FromLocale
(
mrl
[
i
+
1
].
mb_str
()
);
playlist_ItemAddOption
(
p_item
,
psz_utf8
);
LocaleFree
(
psz_utf8
);
i
++
;
}
...
...
@@ -1134,7 +1139,9 @@ void OpenDialog::OnOk( wxCommandEvent& WXUNUSED(event) )
{
for
(
int
j
=
0
;
j
<
(
int
)
subsfile_mrl
.
GetCount
();
j
++
)
{
playlist_ItemAddOption
(
p_item
,
subsfile_mrl
[
j
].
mb_str
()
);
psz_utf8
=
FromLocale
(
subsfile_mrl
[
j
].
mb_str
()
);
playlist_ItemAddOption
(
p_item
,
psz_utf8
);
LocaleFree
(
psz_utf8
);
}
}
...
...
@@ -1143,16 +1150,17 @@ void OpenDialog::OnOk( wxCommandEvent& WXUNUSED(event) )
{
for
(
int
j
=
0
;
j
<
(
int
)
sout_mrl
.
GetCount
();
j
++
)
{
psz_utf8
=
FromLocale
(
sout_mrl
[
j
].
mb_str
()
);
playlist_ItemAddOption
(
p_item
,
sout_mrl
[
j
].
mb_str
()
);
LocaleFree
(
psz_utf8
);
}
}
playlist_AddItem
(
p_playlist
,
p_item
,
PLAYLIST_APPEND
,
PLAYLIST_END
);
playlist_AddItem
(
p_playlist
,
p_item
,
PLAYLIST_APPEND
,
PLAYLIST_END
);
if
(
b_start
)
{
playlist_Control
(
p_playlist
,
PLAYLIST_ITEMPLAY
,
p_item
);
playlist_Control
(
p_playlist
,
PLAYLIST_ITEMPLAY
,
p_item
);
}
}
...
...
modules/gui/wxwidgets/updatevlc.cpp
View file @
1f1820bc
...
...
@@ -625,8 +625,9 @@ void UpdateVLC::OnUpdatesTreeActivate( wxTreeEvent& event )
void
UpdateVLC
::
DownloadFile
(
wxString
url
,
wxString
dst
)
{
char
*
psz_local
=
ToLocale
(
dst
.
mb_str
()
);
msg_Dbg
(
p_intf
,
"Downloading %s to %s"
,
(
const
char
*
)
url
.
mb_str
(),
(
const
char
*
)
dst
.
mb_str
()
);
(
const
char
*
)
url
.
mb_str
(),
psz_local
);
stream_t
*
p_stream
=
NULL
;
p_stream
=
stream_UrlNew
(
p_intf
,
(
const
char
*
)
url
.
mb_str
()
);
...
...
@@ -638,13 +639,14 @@ void UpdateVLC::DownloadFile( wxString url, wxString dst )
}
FILE
*
p_file
=
NULL
;
p_file
=
fopen
(
(
const
char
*
)
dst
.
mb_str
()
,
"w"
);
p_file
=
fopen
(
psz_local
,
"w"
);
if
(
!
p_file
)
{
msg_Err
(
p_intf
,
"Failed to open %s for writing"
,
(
const
char
*
)
dst
.
mb_str
()
);
msg_Err
(
p_intf
,
"Failed to open %s for writing"
,
psz_local
);
// FIXME : display error message in dialog
return
;
}
LocaleFree
(
psz_local
);
int
i_progress
=
0
;
wxProgressDialog
*
progressdialog
=
...
...
modules/gui/wxwidgets/wizard.cpp
View file @
1f1820bc
...
...
@@ -1495,7 +1495,9 @@ void WizardDialog::SetStream( char const *method, char const *address )
void
WizardDialog
::
SetTranscodeOut
(
char
const
*
address
)
{
this
->
address
=
strdup
(
address
);
char
*
psz_utf8
=
FromLocale
(
address
);
this
->
address
=
strdup
(
psz_utf8
);
LocaleFree
(
psz_utf8
);
}
void
WizardDialog
::
SetMux
(
char
const
*
mux
)
...
...
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