Improve organization of NeatBarLayer struct
This commit is contained in:
+11
-4
@@ -6,24 +6,31 @@
|
||||
#include <pebble.h>
|
||||
|
||||
typedef struct {
|
||||
// layerage
|
||||
struct Window *window;
|
||||
GRect main_grect;
|
||||
Layer *main_layer;
|
||||
BitmapLayer *up_layer;
|
||||
BitmapLayer *down_layer;
|
||||
BitmapLayer *select_layer;
|
||||
|
||||
// stock cfg/plumbing
|
||||
ClickConfigProvider click_config_provider;
|
||||
GColor8 background_color;
|
||||
uint16_t corner_radius;
|
||||
uint16_t x_offset;
|
||||
int8_t spread;
|
||||
void *context;
|
||||
|
||||
// neat_bar exclusives :D
|
||||
uint16_t bar_corner_radius;
|
||||
uint16_t bar_x_offset;
|
||||
int8_t icons_spread;
|
||||
bool animations_move_on_y_axis;
|
||||
int8_t animations_move_distance;
|
||||
uint8_t animations_duration;
|
||||
|
||||
// state tracking
|
||||
bool up_pressed;
|
||||
bool select_pressed;
|
||||
bool down_pressed;
|
||||
void *context;
|
||||
} NeatBarLayer;
|
||||
|
||||
void neat_bar_layer_add_to_window(NeatBarLayer *neat_bar, Window *window);
|
||||
|
||||
Reference in New Issue
Block a user