Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
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-1.1
Commits
b67e6fc2
Commit
b67e6fc2
authored
May 14, 2006
by
Felix Paul Kühne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* first implementation of a widget-free authentication-dialogue (core and OSX only, refs #553)
parent
96053dfb
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
17 deletions
+17
-17
include/vlc_interaction.h
include/vlc_interaction.h
+3
-0
modules/gui/macosx/interaction.m
modules/gui/macosx/interaction.m
+7
-5
src/interface/interaction.c
src/interface/interaction.c
+7
-12
No files found.
include/vlc_interaction.h
View file @
b67e6fc2
...
...
@@ -55,6 +55,8 @@ struct interaction_dialog_t
char
*
psz_returned
[
1
];
///< returned responses from the user
vlc_value_t
val
;
///< a value coming from core for dialogue
int
i_widgets
;
///< Number of dialog widgets
user_widget_t
**
pp_widgets
;
///< Dialog widgets
...
...
@@ -80,6 +82,7 @@ struct interaction_dialog_t
#define DIALOG_CLEAR_NOSHOW 0x08
#define DIALOG_GOT_ANSWER 0x10
#define DIALOG_LOGIN_PW_OK_CANCEL 0x20
#define DIALOG_USER_PROGRESS 0x40
/**
* Possible return codes
...
...
modules/gui/macosx/interaction.m
View file @
b67e6fc2
...
...
@@ -192,9 +192,9 @@
modalDelegate
:
self
didEndSelector
:
nil
contextInfo
:
nil
];
[
o_auth_win
makeKeyWindow
];
}
else
if
(
p_dialog
->
i_
type
&
WIDGET
_PROGRESS
)
else
if
(
p_dialog
->
i_
flags
&
DIALOG_USER
_PROGRESS
)
{
msg_Dbg
(
p_intf
,
"requested
type: WIDGET
_PROGRESS"
);
msg_Dbg
(
p_intf
,
"requested
flag: DIALOG_USER
_PROGRESS"
);
[
o_prog_title
setStringValue
:
o_title
];
[
o_prog_description
setStringValue
:
o_description
];
[
o_prog_bar
setDoubleValue
:
0
];
...
...
@@ -236,10 +236,12 @@
int
i
=
0
;
for
(
i
=
0
;
i
<
p_dialog
->
i_widgets
;
i
++
)
{
if
(
p_dialog
->
i_
type
&
WIDGET
_PROGRESS
)
if
(
p_dialog
->
i_
flags
&
DIALOG_USER
_PROGRESS
)
{
[
o_prog_description
setStringValue
:
\
[
NSString
stringWithUTF8String
:
p_dialog
->
psz_description
]];
[
o_prog_bar
setDoubleValue
:
\
(
double
)(
p_dialog
->
pp_widgets
[
i
]
->
val
.
f_float
)];
(
double
)(
p_dialog
->
val
.
f_float
)];
if
(
[
o_prog_bar
doubleValue
]
==
100
.
0
)
{
...
...
@@ -254,7 +256,7 @@
-
(
void
)
hideDialog
{
msg_Dbg
(
p_intf
,
"hide event"
);
if
(
p_dialog
->
i_
type
&
WIDGET
_PROGRESS
)
if
(
p_dialog
->
i_
flags
&
DIALOG_USER
_PROGRESS
)
{
[
NSApp
endSheet
:
o_prog_win
];
[
o_prog_win
close
];
...
...
src/interface/interaction.c
View file @
b67e6fc2
...
...
@@ -339,20 +339,15 @@ int __intf_UserProgress( vlc_object_t *p_this,
{
int
i_ret
;
interaction_dialog_t
*
p_new
=
NULL
;
user_widget_t
*
p_widget
=
NULL
;
INTERACT_INIT
(
p_new
);
p_new
->
i_type
=
INTERACT_DIALOG_ONEWAY
;
p_new
->
psz_title
=
strdup
(
psz_title
);
p_new
->
psz_description
=
strdup
(
psz_status
);
p_new
->
val
.
f_float
=
f_pos
;
/* Progress bar */
p_widget
=
(
user_widget_t
*
)
malloc
(
sizeof
(
user_widget_t
)
);
p_widget
->
i_type
=
WIDGET_PROGRESS
;
p_widget
->
psz_text
=
strdup
(
psz_status
);
p_widget
->
val
.
f_float
=
f_pos
;
INSERT_ELEM
(
p_new
->
pp_widgets
,
p_new
->
i_widgets
,
p_new
->
i_widgets
,
p_widget
);
p_new
->
i_flags
=
DIALOG_USER_PROGRESS
;
i_ret
=
intf_Interact
(
p_this
,
p_new
);
...
...
@@ -383,11 +378,11 @@ void __intf_UserProgressUpdate( vlc_object_t *p_this, int i_id,
return
;
}
if
(
p_dialog
->
p
p_widgets
[
0
]
->
psz_text
)
free
(
p_dialog
->
p
p_widgets
[
0
]
->
psz_text
);
p_dialog
->
p
p_widgets
[
0
]
->
psz_text
=
strdup
(
psz_status
);
if
(
p_dialog
->
p
sz_description
)
free
(
p_dialog
->
p
sz_description
);
p_dialog
->
p
sz_description
=
strdup
(
psz_status
);
p_dialog
->
pp_widgets
[
0
]
->
val
.
f_float
=
f_pos
;
p_dialog
->
val
.
f_float
=
f_pos
;
p_dialog
->
i_status
=
UPDATED_DIALOG
;
vlc_mutex_unlock
(
&
p_interaction
->
object_lock
)
;
...
...
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