mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-10-13 18:17:39 -04:00
pluginlib: made local functions in static and made sure that source files include their own header file.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@17353 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
517aca8532
commit
a36c8f1db3
9 changed files with 23 additions and 19 deletions
|
@ -18,6 +18,7 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "plugin.h"
|
||||
#include "checkbox.h"
|
||||
|
||||
#ifdef HAVE_LCD_BITMAP
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@ void configfile_init(struct plugin_api* newrb)
|
|||
cfg_rb = newrb;
|
||||
}
|
||||
|
||||
void get_cfg_filename(char* buf, int buf_len, const char* filename)
|
||||
static void get_cfg_filename(char* buf, int buf_len, const char* filename)
|
||||
{
|
||||
char *s;
|
||||
cfg_rb->strcpy(buf, cfg_rb->plugin_get_current_filename());
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include <inttypes.h>
|
||||
#include "fixedpoint.h"
|
||||
|
||||
/* Inverse gain of circular cordic rotation in s0.31 format. */
|
||||
static const long cordic_circular_gain = 0xb2458939; /* 0.607252929 */
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "plugin.h"
|
||||
#include "helper.h"
|
||||
|
||||
/* Force the backlight on */
|
||||
void backlight_force_on(struct plugin_api* rb)
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
|
||||
#ifndef SIMULATOR
|
||||
#include "plugin.h"
|
||||
#include "overlay.h"
|
||||
|
||||
/* load and run a plugin linked as an overlay.
|
||||
|
||||
|
|
|
@ -18,17 +18,18 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "plugin.h"
|
||||
#include "playback_control.h"
|
||||
|
||||
struct plugin_api* api = 0;
|
||||
struct viewport *parentvp = NULL;
|
||||
|
||||
bool prevtrack(void)
|
||||
static bool prevtrack(void)
|
||||
{
|
||||
api->audio_prev();
|
||||
return false;
|
||||
}
|
||||
|
||||
bool play(void)
|
||||
static bool play(void)
|
||||
{
|
||||
int audio_status = api->audio_status();
|
||||
if (!audio_status && api->global_status->resume_index != -1)
|
||||
|
@ -46,13 +47,13 @@ bool play(void)
|
|||
return false;
|
||||
}
|
||||
|
||||
bool stop(void)
|
||||
static bool stop(void)
|
||||
{
|
||||
api->audio_stop();
|
||||
return false;
|
||||
}
|
||||
|
||||
bool nexttrack(void)
|
||||
static bool nexttrack(void)
|
||||
{
|
||||
api->audio_next();
|
||||
return false;
|
||||
|
|
|
@ -20,12 +20,11 @@
|
|||
#define __PLAYBACK_CONTROL_H__
|
||||
|
||||
/* Use these if your menu uses the new menu api.
|
||||
REMEBER to call playback_control_init(rb) before rb->do_menu()...
|
||||
REMEMBER to call playback_control_init(rb) before rb->do_menu()...
|
||||
The parent viewport here is needed by the internal functions,
|
||||
So, make sure you use the same viewport for the rb->do_menu() call
|
||||
that you use in the playback_control_init() call
|
||||
*/
|
||||
extern const struct menu_item_ex playback_control_menu;
|
||||
void playback_control_init(struct plugin_api* newapi,
|
||||
struct viewport parent[NB_SCREENS]);
|
||||
|
||||
|
|
|
@ -456,7 +456,7 @@ static int plugin_context_count = 0;
|
|||
static int last_context = 0; /* index into plugin_context_order
|
||||
of the last context returned */
|
||||
|
||||
const struct button_mapping* get_context_map(int context)
|
||||
static const struct button_mapping* get_context_map(int context)
|
||||
{
|
||||
(void)context;
|
||||
if (last_context<plugin_context_count)
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
#include "xlcd.h"
|
||||
|
||||
/* sort the given coordinates by increasing x value */
|
||||
void sort_points_by_increasing_x(int* x1, int* y1,
|
||||
static void sort_points_by_increasing_x(int* x1, int* y1,
|
||||
int* x2, int* y2,
|
||||
int* x3, int* y3)
|
||||
{
|
||||
|
@ -69,7 +69,7 @@ void sort_points_by_increasing_x(int* x1, int* y1,
|
|||
sort_points_by_increasing_x(y1, x1, y2, x2, y3, x3)
|
||||
|
||||
/* draw a filled triangle, using horizontal lines for speed */
|
||||
void xlcd_filltriangle_horizontal(struct screen* display,
|
||||
static void xlcd_filltriangle_horizontal(struct screen* display,
|
||||
int x1, int y1,
|
||||
int x2, int y2,
|
||||
int x3, int y3)
|
||||
|
@ -109,7 +109,7 @@ void xlcd_filltriangle_horizontal(struct screen* display,
|
|||
}
|
||||
|
||||
/* draw a filled triangle, using vertical lines for speed */
|
||||
void xlcd_filltriangle_vertical(struct screen* display,
|
||||
static void xlcd_filltriangle_vertical(struct screen* display,
|
||||
int x1, int y1,
|
||||
int x2, int y2,
|
||||
int x3, int y3)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue