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
9f176200
Commit
9f176200
authored
May 11, 2011
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update message callback
- remove always zero overruns counter, - constify message pointer.
parent
1075ddb2
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
10 additions
and
14 deletions
+10
-14
include/vlc_messages.h
include/vlc_messages.h
+1
-1
modules/gui/macosx/intf.m
modules/gui/macosx/intf.m
+2
-2
modules/gui/ncurses.c
modules/gui/ncurses.c
+1
-2
modules/gui/qt4/dialogs/messages.cpp
modules/gui/qt4/dialogs/messages.cpp
+2
-3
modules/misc/logger.c
modules/misc/logger.c
+2
-3
src/control/log.c
src/control/log.c
+1
-2
src/misc/messages.c
src/misc/messages.c
+1
-1
No files found.
include/vlc_messages.h
View file @
9f176200
...
...
@@ -117,7 +117,7 @@ typedef struct msg_cb_data_t msg_cb_data_t;
* Message logging callback signature.
* Accepts one private data pointer, the message, and an overrun counter.
*/
typedef
void
(
*
msg_callback_t
)
(
msg_cb_data_t
*
,
msg_item_t
*
,
unsigned
);
typedef
void
(
*
msg_callback_t
)
(
msg_cb_data_t
*
,
const
msg_item_t
*
);
VLC_API
msg_subscription_t
*
msg_Subscribe
(
libvlc_int_t
*
,
msg_callback_t
,
msg_cb_data_t
*
)
VLC_USED
;
VLC_API
void
msg_Unsubscribe
(
msg_subscription_t
*
);
...
...
modules/gui/macosx/intf.m
View file @
9f176200
...
...
@@ -71,7 +71,7 @@ static void updateProgressPanel (void *, const char *, float);
static
bool
checkProgressPanel
(
void
*
);
static
void
destroyProgressPanel
(
void
*
);
static
void
MsgCallback
(
msg_cb_data_t
*
,
msg_item_t
*
,
unsigned
);
static
void
MsgCallback
(
msg_cb_data_t
*
,
const
msg_item_t
*
);
#pragma mark -
#pragma mark VLC Interface Object Callbacks
...
...
@@ -153,7 +153,7 @@ static void Run( intf_thread_t *p_intf )
* ready to be displayed. We store everything in a NSArray in our Cocoa part
* of this file, so we are forwarding everything through notifications.
*****************************************************************************/
static
void
MsgCallback
(
msg_cb_data_t
*
data
,
msg_item_t
*
item
,
unsigned
int
i
)
static
void
MsgCallback
(
msg_cb_data_t
*
data
,
const
msg_item_t
*
item
)
{
int
canc
=
vlc_savecancel
();
NSAutoreleasePool
*
o_pool
=
[[
NSAutoreleasePool
alloc
]
init
];
...
...
modules/gui/ncurses.c
View file @
9f176200
...
...
@@ -1773,10 +1773,9 @@ static void HandleKey(intf_thread_t *p_intf)
*
*/
static
void
MsgCallback
(
msg_cb_data_t
*
data
,
msg_item_t
*
msg
,
unsigned
i
)
static
void
MsgCallback
(
msg_cb_data_t
*
data
,
const
msg_item_t
*
msg
)
{
intf_sys_t
*
p_sys
=
data
->
p_sys
;
(
void
)
i
;
// what is this?
int
canc
=
vlc_savecancel
();
vlc_mutex_lock
(
&
p_sys
->
msg_lock
);
...
...
modules/gui/qt4/dialogs/messages.cpp
View file @
9f176200
...
...
@@ -73,7 +73,7 @@ struct msg_cb_data_t
MessagesDialog
*
self
;
};
static
void
MsgCallback
(
msg_cb_data_t
*
,
msg_item_t
*
,
unsigned
);
static
void
MsgCallback
(
msg_cb_data_t
*
,
const
msg_item_t
*
);
MessagesDialog
::
MessagesDialog
(
intf_thread_t
*
_p_intf
)
:
QVLCFrame
(
_p_intf
)
...
...
@@ -296,7 +296,7 @@ void MessagesDialog::tabChanged( int i )
updateButton
->
setVisible
(
i
==
1
);
}
static
void
MsgCallback
(
msg_cb_data_t
*
data
,
msg_item_t
*
item
,
unsigned
)
static
void
MsgCallback
(
msg_cb_data_t
*
data
,
const
msg_item_t
*
item
)
{
int
canc
=
vlc_savecancel
();
...
...
@@ -304,4 +304,3 @@ static void MsgCallback( msg_cb_data_t *data, msg_item_t *item, unsigned )
vlc_restorecancel
(
canc
);
}
modules/misc/logger.c
View file @
9f176200
...
...
@@ -94,7 +94,7 @@ struct intf_sys_t
static
int
Open
(
vlc_object_t
*
);
static
void
Close
(
vlc_object_t
*
);
static
void
Overflow
(
msg_cb_data_t
*
p_sys
,
msg_item_t
*
p_item
,
unsigned
overruns
);
static
void
Overflow
(
msg_cb_data_t
*
p_sys
,
const
msg_item_t
*
p_item
);
static
void
TextPrint
(
const
msg_item_t
*
,
FILE
*
);
static
void
HtmlPrint
(
const
msg_item_t
*
,
FILE
*
);
#ifdef HAVE_SYSLOG_H
...
...
@@ -366,9 +366,8 @@ static void Close( vlc_object_t *p_this )
/**
* Log a message
*/
static
void
Overflow
(
msg_cb_data_t
*
p_sys
,
msg_item_t
*
p_item
,
unsigned
overruns
)
static
void
Overflow
(
msg_cb_data_t
*
p_sys
,
const
msg_item_t
*
p_item
)
{
VLC_UNUSED
(
overruns
);
int
verbosity
=
var_InheritInteger
(
p_sys
->
p_intf
,
"log-verbose"
);
if
(
verbosity
==
-
1
)
verbosity
=
var_InheritInteger
(
p_sys
->
p_intf
,
"verbose"
);
...
...
src/control/log.c
View file @
9f176200
...
...
@@ -48,7 +48,7 @@ struct msg_cb_data_t
int
verbosity
;
};
static
void
handler
(
msg_cb_data_t
*
d
,
msg_item_t
*
p_item
,
unsigned
i_drop
)
static
void
handler
(
msg_cb_data_t
*
d
,
const
msg_item_t
*
p_item
)
{
if
(
p_item
->
i_type
>
d
->
verbosity
)
return
;
...
...
@@ -59,7 +59,6 @@ static void handler( msg_cb_data_t *d, msg_item_t *p_item, unsigned i_drop )
if
(
d
->
count
<
VLC_MSG_QSIZE
)
d
->
items
[
d
->
count
++
]
=
msg
;
vlc_spin_unlock
(
&
d
->
lock
);
(
void
)
i_drop
;
}
struct
libvlc_log_t
...
...
src/misc/messages.c
View file @
9f176200
...
...
@@ -413,7 +413,7 @@ void msg_GenericVa (vlc_object_t *p_this, int i_type,
break
;
}
sub
->
func
(
sub
->
opaque
,
&
msg
,
0
);
sub
->
func
(
sub
->
opaque
,
&
msg
);
}
vlc_rwlock_unlock
(
&
bank
->
lock
);
free
(
msg
.
psz_msg
);
...
...
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