lcd-16bit: Remove {lss,lse,lst}_pattern fields from struct viewport.
These where used for line styling during scrolling, which is now done in apps/,
The viewport struct doesn't need to record these anymore.
Change-Id: I810d9dcb2644b00a798c6e75acab69c74a78e77f
diff --git a/apps/gui/skin_engine/skin_parser.c b/apps/gui/skin_engine/skin_parser.c
index 1945bfb..1946e17 100644
--- a/apps/gui/skin_engine/skin_parser.c
+++ b/apps/gui/skin_engine/skin_parser.c
@@ -1957,9 +1957,9 @@
skin_vp->start_bgcolour = skin_vp->vp.bg_pattern;
#endif
#ifdef HAVE_LCD_COLOR
- skin_vp->start_gradient.start = skin_vp->vp.lss_pattern;
- skin_vp->start_gradient.end = skin_vp->vp.lse_pattern;
- skin_vp->start_gradient.text = skin_vp->vp.lst_pattern;
+ skin_vp->start_gradient.start = global_settings.lss_color;
+ skin_vp->start_gradient.end = global_settings.lse_color;
+ skin_vp->start_gradient.text = global_settings.lst_color;
#endif
diff --git a/apps/gui/skin_engine/skin_render.c b/apps/gui/skin_engine/skin_render.c
index f40c3b9..4391469 100644
--- a/apps/gui/skin_engine/skin_render.c
+++ b/apps/gui/skin_engine/skin_render.c
@@ -859,11 +859,6 @@
skin_backdrop_show(data->backdrop_id);
}
#endif
-#ifdef HAVE_LCD_COLOR
- skin_viewport->vp.lss_pattern = skin_viewport->start_gradient.start;
- skin_viewport->vp.lse_pattern = skin_viewport->start_gradient.end;
- skin_viewport->vp.lst_pattern = skin_viewport->start_gradient.text;
-#endif
/* dont redraw the viewport if its disabled */
if (skin_viewport->hidden_flags&VP_NEVER_VISIBLE)
diff --git a/apps/gui/viewport.c b/apps/gui/viewport.c
index b91c744..aeb884a 100644
--- a/apps/gui/viewport.c
+++ b/apps/gui/viewport.c
@@ -329,11 +329,6 @@
{
vp->fg_pattern = FG_FALLBACK;
vp->bg_pattern = BG_FALLBACK;
-#ifdef HAVE_LCD_COLOR
- vp->lss_pattern = global_settings.lss_color;
- vp->lse_pattern = global_settings.lse_color;
- vp->lst_pattern = global_settings.lst_color;
-#endif
}
#endif
diff --git a/apps/plugins/lua/rocklib.c b/apps/plugins/lua/rocklib.c
index 1290a7f..27c1177 100644
--- a/apps/plugins/lua/rocklib.c
+++ b/apps/plugins/lua/rocklib.c
@@ -240,11 +240,6 @@
#if LCD_DEPTH > 1
check_tablevalue(L, "fg_pattern", tablepos, &vp->fg_pattern, true);
check_tablevalue(L, "bg_pattern", tablepos, &vp->bg_pattern, true);
-#ifdef HAVE_LCD_COLOR
- check_tablevalue(L, "lss_pattern", tablepos, &vp->lss_pattern, true);
- check_tablevalue(L, "lse_pattern", tablepos, &vp->lse_pattern, true);
- check_tablevalue(L, "lst_pattern", tablepos, &vp->lst_pattern, true);
-#endif
#endif
return vp;
diff --git a/apps/plugins/reversi/reversi-gui.c b/apps/plugins/reversi/reversi-gui.c
index e59a91e..39a7d2d 100644
--- a/apps/plugins/reversi/reversi-gui.c
+++ b/apps/plugins/reversi/reversi-gui.c
@@ -188,9 +188,6 @@
* int drawmode- Modes defined in lcd.h
* unsigned fg_pattern - foreground color
* unsigned bg_pattern - backbround color
- * unsigned lss_pattern - Selector colors (currently unused)
- * unsigned lse_pattern - |
- * unsigned lst_pattern - \/
*
* The rest of the touch button elements are:
* bool repeat - requires the area be held for the action
diff --git a/apps/plugins/test_viewports.c b/apps/plugins/test_viewports.c
index be61c77..9fc9caa 100644
--- a/apps/plugins/test_viewports.c
+++ b/apps/plugins/test_viewports.c
@@ -47,11 +47,6 @@
.fg_pattern = LCD_DEFAULT_FG,
.bg_pattern = BGCOLOR_1,
#endif
-#ifdef HAVE_LCD_COLOR
- .lss_pattern = LCD_DEFAULT_BG,
- .lse_pattern = LCD_DEFAULT_BG,
- .lst_pattern = LCD_DEFAULT_BG,
-#endif
};
static struct viewport vp1 =
@@ -65,11 +60,6 @@
#if LCD_DEPTH > 1
.fg_pattern = LCD_DEFAULT_FG,
.bg_pattern = LCD_DEFAULT_BG,
-#ifdef HAVE_LCD_COLOR
- .lss_pattern = LCD_DEFAULT_BG,
- .lse_pattern = LCD_DEFAULT_BG,
- .lst_pattern = LCD_DEFAULT_BG,
-#endif
#endif
};
@@ -84,11 +74,6 @@
#if LCD_DEPTH > 1
.fg_pattern = FGCOLOR_1,
.bg_pattern = BGCOLOR_2,
-#ifdef HAVE_LCD_COLOR
- .lss_pattern = LCD_DEFAULT_BG,
- .lse_pattern = LCD_DEFAULT_BG,
- .lst_pattern = LCD_DEFAULT_BG,
-#endif
#endif
};
@@ -104,11 +89,6 @@
#if LCD_DEPTH > 1
.fg_pattern = LCD_BLACK,
.bg_pattern = LCD_WHITE,
-#ifdef HAVE_LCD_COLOR
- .lss_pattern = LCD_DEFAULT_BG,
- .lse_pattern = LCD_DEFAULT_BG,
- .lst_pattern = LCD_DEFAULT_BG,
-#endif
#endif
};
diff --git a/apps/screen_access.c b/apps/screen_access.c
index 31a9460..1c339d9 100644
--- a/apps/screen_access.c
+++ b/apps/screen_access.c
@@ -231,11 +231,6 @@
.get_foreground=&lcd_get_foreground,
.set_background=&lcd_set_background,
.set_foreground=&lcd_set_foreground,
-#ifdef HAVE_LCD_COLOR
- .set_selector_start=&lcd_set_selector_start,
- .set_selector_end=&lcd_set_selector_end,
- .set_selector_text=&lcd_set_selector_text,
-#endif
#endif /* LCD_DEPTH > 1 */
.update_rect=&lcd_update_rect,
.update_viewport_rect=&lcd_update_viewport_rect,
diff --git a/apps/screen_access.h b/apps/screen_access.h
index c5684fc..7efc38b 100644
--- a/apps/screen_access.h
+++ b/apps/screen_access.h
@@ -102,11 +102,6 @@
void (*set_background)(unsigned background);
void (*set_foreground)(unsigned foreground);
#endif /* (LCD_DEPTH > 1) || (LCD_REMOTE_DEPTH > 1) */
-#if defined(HAVE_LCD_COLOR)
- void (*set_selector_start)(unsigned selector);
- void (*set_selector_end)(unsigned selector);
- void (*set_selector_text)(unsigned selector_text);
-#endif
void (*update_rect)(int x, int y, int width, int height);
void (*update_viewport_rect)(int x, int y, int width, int height);
void (*fillrect)(int x, int y, int width, int height);
diff --git a/apps/settings.c b/apps/settings.c
index 1d92df2..e4a44da 100644
--- a/apps/settings.c
+++ b/apps/settings.c
@@ -994,9 +994,6 @@
#ifdef HAVE_LCD_COLOR
screens[SCREEN_MAIN].set_foreground(global_settings.fg_color);
screens[SCREEN_MAIN].set_background(global_settings.bg_color);
- screens[SCREEN_MAIN].set_selector_start(global_settings.lss_color);
- screens[SCREEN_MAIN].set_selector_end(global_settings.lse_color);
- screens[SCREEN_MAIN].set_selector_text(global_settings.lst_color);
#endif
#ifdef HAVE_LCD_BITMAP
diff --git a/firmware/drivers/lcd-16bit-common.c b/firmware/drivers/lcd-16bit-common.c
index 9d36499..93e7c2e 100644
--- a/firmware/drivers/lcd-16bit-common.c
+++ b/firmware/drivers/lcd-16bit-common.c
@@ -52,9 +52,6 @@
.drawmode = DRMODE_SOLID,
.fg_pattern = LCD_DEFAULT_FG,
.bg_pattern = LCD_DEFAULT_BG,
- .lss_pattern = LCD_DEFAULT_BG,
- .lse_pattern = LCD_DEFAULT_BG,
- .lst_pattern = LCD_DEFAULT_BG,
};
static struct viewport* current_vp IDATA_ATTR = &default_vp;
@@ -181,21 +178,6 @@
return current_vp->bg_pattern;
}
-void lcd_set_selector_start(unsigned color)
-{
- current_vp->lss_pattern = color;
-}
-
-void lcd_set_selector_end(unsigned color)
-{
- current_vp->lse_pattern = color;
-}
-
-void lcd_set_selector_text(unsigned color)
-{
- current_vp->lst_pattern = color;
-}
-
void lcd_set_drawinfo(int mode, unsigned fg_color, unsigned bg_color)
{
lcd_set_drawmode(mode);
diff --git a/firmware/export/lcd.h b/firmware/export/lcd.h
index e7a75e8..9efec9d 100644
--- a/firmware/export/lcd.h
+++ b/firmware/export/lcd.h
@@ -48,11 +48,6 @@
#if LCD_DEPTH > 1
unsigned fg_pattern;
unsigned bg_pattern;
-#ifdef HAVE_LCD_COLOR
- unsigned lss_pattern;
- unsigned lse_pattern;
- unsigned lst_pattern;
-#endif
#endif
};