From 0281b1eba84127bef927d70245739e4e55ad5be2 Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Mon, 28 Apr 2014 09:08:26 +0300 Subject: GUI: Added support for PNG images --- gui/ThemeEngine.cpp | 58 +++++++++++++++++++++++++++++++++++++++-------------- 1 file changed, 43 insertions(+), 15 deletions(-) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index c850a6a02e..70ce07b211 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -36,6 +36,7 @@ #include "graphics/fonts/ttf.h" #include "image/bmp.h" +#include "image/png.h" #include "gui/widget.h" #include "gui/ThemeEngine.h" @@ -706,24 +707,51 @@ bool ThemeEngine::addBitmap(const Common::String &filename) { if (surf) return true; - // If not, try to load the bitmap via the BitmapDecoder class. - Image::BitmapDecoder bitmapDecoder; const Graphics::Surface *srcSurface = 0; - Common::ArchiveMemberList members; - _themeFiles.listMatchingMembers(members, filename); - for (Common::ArchiveMemberList::const_iterator i = members.begin(), end = members.end(); i != end; ++i) { - Common::SeekableReadStream *stream = (*i)->createReadStream(); - if (stream) { - bitmapDecoder.loadStream(*stream); - srcSurface = bitmapDecoder.getSurface(); - delete stream; - if (srcSurface) - break; + + if (filename.hasSuffix(".png")) { + // Maybe it is PNG? +#ifdef USE_PNG + Image::PNGDecoder decoder; + Common::ArchiveMemberList members; + _themeFiles.listMatchingMembers(members, filename); + for (Common::ArchiveMemberList::const_iterator i = members.begin(), end = members.end(); i != end; ++i) { + Common::SeekableReadStream *stream = (*i)->createReadStream(); + if (stream) { + if (!decoder.loadStream(*stream)) + error("Error decoding PNG"); + + srcSurface = decoder.getSurface(); + delete stream; + if (srcSurface) + break; + } + } + + if (srcSurface && srcSurface->format.bytesPerPixel != 1) + surf = srcSurface->convertTo(_overlayFormat); +#else + error("No PNG support compiled in"); +#endif + } else { + // If not, try to load the bitmap via the BitmapDecoder class. + Image::BitmapDecoder bitmapDecoder; + Common::ArchiveMemberList members; + _themeFiles.listMatchingMembers(members, filename); + for (Common::ArchiveMemberList::const_iterator i = members.begin(), end = members.end(); i != end; ++i) { + Common::SeekableReadStream *stream = (*i)->createReadStream(); + if (stream) { + bitmapDecoder.loadStream(*stream); + srcSurface = bitmapDecoder.getSurface(); + delete stream; + if (srcSurface) + break; + } } - } - if (srcSurface && srcSurface->format.bytesPerPixel != 1) - surf = srcSurface->convertTo(_overlayFormat); + if (srcSurface && srcSurface->format.bytesPerPixel != 1) + surf = srcSurface->convertTo(_overlayFormat); + } // Store the surface into our hashmap (attention, may store NULL entries!) _bitmaps[filename] = surf; -- cgit v1.2.3 From 53a42ececfff48b93cef414bc2762806786da8d5 Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Fri, 2 May 2014 23:36:03 +0300 Subject: GUI: Added new alphabitmap image type --- gui/ThemeEngine.cpp | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 63 insertions(+), 2 deletions(-) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index 70ce07b211..1a648b44a0 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -31,6 +31,7 @@ #include "graphics/cursorman.h" #include "graphics/fontman.h" #include "graphics/surface.h" +#include "graphics/transparent_surface.h" #include "graphics/VectorRenderer.h" #include "graphics/fonts/bdf.h" #include "graphics/fonts/ttf.h" @@ -309,7 +310,7 @@ void ThemeItemBitmap::drawSelf(bool draw, bool restore) { if (draw) { if (_alpha) - _engine->renderer()->blitAlphaBitmap(_bitmap, _area); + _engine->renderer()->blitKeyBitmap(_bitmap, _area); else _engine->renderer()->blitSubSurface(_bitmap, _area); } @@ -323,7 +324,7 @@ void ThemeItemBitmapClip::drawSelf(bool draw, bool restore) { if (draw) { if (_alpha) - _engine->renderer()->blitAlphaBitmapClip(_bitmap, _area, _clip); + _engine->renderer()->blitKeyBitmapClip(_bitmap, _area, _clip); else _engine->renderer()->blitSubSurfaceClip(_bitmap, _area, _clip); } @@ -402,6 +403,15 @@ ThemeEngine::~ThemeEngine() { } _bitmaps.clear(); + for (AImagesMap::iterator i = _abitmaps.begin(); i != _abitmaps.end(); ++i) { + Graphics::TransparentSurface *surf = i->_value; + if (surf) { + surf->free(); + delete surf; + } + } + _abitmaps.clear(); + delete _parser; delete _themeEval; delete[] _cursor; @@ -526,6 +536,15 @@ void ThemeEngine::refresh() { } } _bitmaps.clear(); + + for (AImagesMap::iterator i = _abitmaps.begin(); i != _abitmaps.end(); ++i) { + Graphics::TransparentSurface *surf = i->_value; + if (surf) { + surf->free(); + delete surf; + } + } + _abitmaps.clear(); } init(); @@ -759,6 +778,48 @@ bool ThemeEngine::addBitmap(const Common::String &filename) { return surf != 0; } +bool ThemeEngine::addAlphaBitmap(const Common::String &filename) { + // Nothing has to be done if the bitmap already has been loaded. + Graphics::TransparentSurface *surf = _abitmaps[filename]; + if (surf) + return true; + + const Graphics::TransparentSurface *srcSurface = 0; + + if (filename.hasSuffix(".png")) { + // Maybe it is PNG? +#ifdef USE_PNG + Image::PNGDecoder decoder; + Common::ArchiveMemberList members; + _themeFiles.listMatchingMembers(members, filename); + for (Common::ArchiveMemberList::const_iterator i = members.begin(), end = members.end(); i != end; ++i) { + Common::SeekableReadStream *stream = (*i)->createReadStream(); + if (stream) { + if (!decoder.loadStream(*stream)) + error("Error decoding PNG"); + + srcSurface = new Graphics::TransparentSurface(*decoder.getSurface(), true); + delete stream; + if (srcSurface) + break; + } + } + + if (srcSurface && srcSurface->format.bytesPerPixel != 1) + surf = srcSurface->convertTo(_overlayFormat); +#else + error("No PNG support compiled in"); +#endif + } else { + error("Only PNG is supported as alphabitmap"); + } + + // Store the surface into our hashmap (attention, may store NULL entries!) + _abitmaps[filename] = surf; + + return surf != 0; +} + bool ThemeEngine::addDrawData(const Common::String &data, bool cached) { DrawData id = parseDrawDataId(data); -- cgit v1.2.3 From f0c52096f3e9215cb584b3862f2cd4b9632761d5 Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Sat, 3 May 2014 02:50:47 +0300 Subject: GUI: Implemented possibility to use alphabitmaps in GraphicsWidget --- gui/ThemeEngine.cpp | 47 +++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 45 insertions(+), 2 deletions(-) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index 1a648b44a0..26729b916f 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -170,11 +170,22 @@ protected: bool _alpha; }; +class ThemeItemABitmap : public ThemeItem { +public: + ThemeItemABitmap(ThemeEngine *engine, const Common::Rect &area, Graphics::TransparentSurface *bitmap, bool alpha) : + ThemeItem(engine, area), _bitmap(bitmap), _alpha(alpha) {} + + void drawSelf(bool draw, bool restore); + +protected: + Graphics::TransparentSurface *_bitmap; + bool _alpha; +}; + class ThemeItemBitmapClip : public ThemeItem { public: ThemeItemBitmapClip(ThemeEngine *engine, const Common::Rect &area, const Common::Rect &clip, const Graphics::Surface *bitmap, bool alpha) : ThemeItem(engine, area), _bitmap(bitmap), _alpha(alpha), _clip(clip) {} - void drawSelf(bool draw, bool restore); protected: @@ -318,10 +329,20 @@ void ThemeItemBitmap::drawSelf(bool draw, bool restore) { _engine->addDirtyRect(_area); } -void ThemeItemBitmapClip::drawSelf(bool draw, bool restore) { +void ThemeItemABitmap::drawSelf(bool draw, bool restore) { if (restore) _engine->restoreBackground(_area); + if (draw) + _engine->renderer()->blitAlphaBitmap(_bitmap, _area); + + _engine->addDirtyRect(_area); +} + +void ThemeItemBitmapClip::drawSelf(bool draw, bool restore) { + if (restore) + _engine->restoreBackground(_area); + if (draw) { if (_alpha) _engine->renderer()->blitKeyBitmapClip(_bitmap, _area, _clip); @@ -1093,6 +1114,21 @@ void ThemeEngine::queueBitmap(const Graphics::Surface *bitmap, const Common::Rec } } +void ThemeEngine::queueABitmap(Graphics::TransparentSurface *bitmap, const Common::Rect &r, bool alpha) { + + Common::Rect area = r; + area.clip(_screen.w, _screen.h); + + ThemeItemABitmap *q = new ThemeItemABitmap(this, area, bitmap, alpha); + + if (_buffering) { + _screenQueue.push_back(q); + } else { + q->drawSelf(true, false); + delete q; + } +} + void ThemeEngine::queueBitmapClip(const Graphics::Surface *bitmap, const Common::Rect &r, const Common::Rect &clip, bool alpha) { Common::Rect area = r; @@ -1481,6 +1517,13 @@ void ThemeEngine::drawSurface(const Common::Rect &r, const Graphics::Surface &su queueBitmap(&surface, r, themeTrans); } +void ThemeEngine::drawASurface(const Common::Rect &r, Graphics::TransparentSurface &surface, WidgetStateInfo state, int alpha, bool themeTrans) { + if (!ready()) + return; + + queueABitmap(&surface, r, themeTrans); +} + void ThemeEngine::drawSurfaceClip(const Common::Rect &r, const Common::Rect &clip, const Graphics::Surface &surface, WidgetStateInfo state, int alpha, bool themeTrans) { if (!ready()) return; -- cgit v1.2.3 From 4474ccf8144563c4bacbb060c943c0f68e317cea Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Mon, 5 May 2014 00:52:56 +0300 Subject: GUI: Implemented alphabitmap autoscale --- gui/ThemeEngine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index 26729b916f..545b9b5c56 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -334,7 +334,7 @@ void ThemeItemABitmap::drawSelf(bool draw, bool restore) { _engine->restoreBackground(_area); if (draw) - _engine->renderer()->blitAlphaBitmap(_bitmap, _area); + _engine->renderer()->blitAlphaBitmap(_bitmap, _area, false); _engine->addDirtyRect(_area); } -- cgit v1.2.3 From ec7312ac13ce19f64b2b453b43e2c37235dcbe7a Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Mon, 5 May 2014 21:36:16 +0300 Subject: GUI: Implemented more modes to autoscale --- gui/ThemeEngine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index 545b9b5c56..26729b916f 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -334,7 +334,7 @@ void ThemeItemABitmap::drawSelf(bool draw, bool restore) { _engine->restoreBackground(_area); if (draw) - _engine->renderer()->blitAlphaBitmap(_bitmap, _area, false); + _engine->renderer()->blitAlphaBitmap(_bitmap, _area); _engine->addDirtyRect(_area); } -- cgit v1.2.3 From 75f9b099dc3e198c7a1750a6e26ac4945719492f Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Fri, 9 May 2014 19:00:49 +0300 Subject: GUI: Added possibility to specify scale mode for AlphaBitmaps --- gui/ThemeEngine.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index 26729b916f..57c2e5d870 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -172,14 +172,14 @@ protected: class ThemeItemABitmap : public ThemeItem { public: - ThemeItemABitmap(ThemeEngine *engine, const Common::Rect &area, Graphics::TransparentSurface *bitmap, bool alpha) : - ThemeItem(engine, area), _bitmap(bitmap), _alpha(alpha) {} + ThemeItemABitmap(ThemeEngine *engine, const Common::Rect &area, Graphics::TransparentSurface *bitmap, ThemeEngine::AutoScaleMode autoscale) : + ThemeItem(engine, area), _bitmap(bitmap), _autoscale(autoscale) {} void drawSelf(bool draw, bool restore); protected: Graphics::TransparentSurface *_bitmap; - bool _alpha; + ThemeEngine::AutoScaleMode _autoscale; }; class ThemeItemBitmapClip : public ThemeItem { @@ -334,7 +334,7 @@ void ThemeItemABitmap::drawSelf(bool draw, bool restore) { _engine->restoreBackground(_area); if (draw) - _engine->renderer()->blitAlphaBitmap(_bitmap, _area); + _engine->renderer()->blitAlphaBitmap(_bitmap, _area, _autoscale); _engine->addDirtyRect(_area); } @@ -1114,12 +1114,12 @@ void ThemeEngine::queueBitmap(const Graphics::Surface *bitmap, const Common::Rec } } -void ThemeEngine::queueABitmap(Graphics::TransparentSurface *bitmap, const Common::Rect &r, bool alpha) { +void ThemeEngine::queueABitmap(Graphics::TransparentSurface *bitmap, const Common::Rect &r, AutoScaleMode autoscale) { Common::Rect area = r; area.clip(_screen.w, _screen.h); - ThemeItemABitmap *q = new ThemeItemABitmap(this, area, bitmap, alpha); + ThemeItemABitmap *q = new ThemeItemABitmap(this, area, bitmap, autoscale); if (_buffering) { _screenQueue.push_back(q); @@ -1517,11 +1517,11 @@ void ThemeEngine::drawSurface(const Common::Rect &r, const Graphics::Surface &su queueBitmap(&surface, r, themeTrans); } -void ThemeEngine::drawASurface(const Common::Rect &r, Graphics::TransparentSurface &surface, WidgetStateInfo state, int alpha, bool themeTrans) { +void ThemeEngine::drawASurface(const Common::Rect &r, Graphics::TransparentSurface &surface, AutoScaleMode autoscale) { if (!ready()) return; - queueABitmap(&surface, r, themeTrans); + queueABitmap(&surface, r, autoscale); } void ThemeEngine::drawSurfaceClip(const Common::Rect &r, const Common::Rect &clip, const Graphics::Surface &surface, WidgetStateInfo state, int alpha, bool themeTrans) { -- cgit v1.2.3 From 1359255ea83f596fbce3332d7d54f9acbc4daf4d Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Thu, 29 May 2014 19:42:34 +0300 Subject: GUI: Added empty dialog background --- gui/ThemeEngine.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index 57c2e5d870..ee860ffbf9 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -1416,6 +1416,8 @@ void ThemeEngine::drawDialogBackground(const Common::Rect &r, DialogBackground b case kDialogBackgroundDefault: queueDD(kDDDefaultBackground, r); break; + case kDialogBackgroundNone: + break; } } -- cgit v1.2.3 From 6524a8d103c87def348b9560418850cb48d24ce4 Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Mon, 4 Aug 2014 01:12:49 +0200 Subject: GUI: Added transparency to PicWidgets --- gui/ThemeEngine.cpp | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index ee860ffbf9..e0563da711 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -172,14 +172,15 @@ protected: class ThemeItemABitmap : public ThemeItem { public: - ThemeItemABitmap(ThemeEngine *engine, const Common::Rect &area, Graphics::TransparentSurface *bitmap, ThemeEngine::AutoScaleMode autoscale) : - ThemeItem(engine, area), _bitmap(bitmap), _autoscale(autoscale) {} + ThemeItemABitmap(ThemeEngine *engine, const Common::Rect &area, Graphics::TransparentSurface *bitmap, ThemeEngine::AutoScaleMode autoscale, int alpha) : + ThemeItem(engine, area), _bitmap(bitmap), _autoscale(autoscale), _alpha(alpha) {} void drawSelf(bool draw, bool restore); protected: Graphics::TransparentSurface *_bitmap; ThemeEngine::AutoScaleMode _autoscale; + int _alpha; }; class ThemeItemBitmapClip : public ThemeItem { @@ -334,7 +335,7 @@ void ThemeItemABitmap::drawSelf(bool draw, bool restore) { _engine->restoreBackground(_area); if (draw) - _engine->renderer()->blitAlphaBitmap(_bitmap, _area, _autoscale); + _engine->renderer()->blitAlphaBitmap(_bitmap, _area, _autoscale, Graphics::DrawStep::kVectorAlignManual, Graphics::DrawStep::kVectorAlignManual, _alpha); _engine->addDirtyRect(_area); } @@ -1114,12 +1115,12 @@ void ThemeEngine::queueBitmap(const Graphics::Surface *bitmap, const Common::Rec } } -void ThemeEngine::queueABitmap(Graphics::TransparentSurface *bitmap, const Common::Rect &r, AutoScaleMode autoscale) { +void ThemeEngine::queueABitmap(Graphics::TransparentSurface *bitmap, const Common::Rect &r, AutoScaleMode autoscale, int alpha) { Common::Rect area = r; area.clip(_screen.w, _screen.h); - ThemeItemABitmap *q = new ThemeItemABitmap(this, area, bitmap, autoscale); + ThemeItemABitmap *q = new ThemeItemABitmap(this, area, bitmap, autoscale, alpha); if (_buffering) { _screenQueue.push_back(q); @@ -1519,11 +1520,11 @@ void ThemeEngine::drawSurface(const Common::Rect &r, const Graphics::Surface &su queueBitmap(&surface, r, themeTrans); } -void ThemeEngine::drawASurface(const Common::Rect &r, Graphics::TransparentSurface &surface, AutoScaleMode autoscale) { +void ThemeEngine::drawASurface(const Common::Rect &r, Graphics::TransparentSurface &surface, AutoScaleMode autoscale, int alpha) { if (!ready()) return; - queueABitmap(&surface, r, autoscale); + queueABitmap(&surface, r, autoscale, alpha); } void ThemeEngine::drawSurfaceClip(const Common::Rect &r, const Common::Rect &clip, const Graphics::Surface &surface, WidgetStateInfo state, int alpha, bool themeTrans) { -- cgit v1.2.3 From c7fe842f9acf0eeec5453170699ed10394ef0fa5 Mon Sep 17 00:00:00 2001 From: Alexander Tkachev Date: Wed, 20 Jul 2016 16:56:21 +0600 Subject: GUI: Fix texts clipping If it was completely clipped out (empty rectangle), it was drawing the whole text ("empty means no clipping"), so I had to detect such cases and change textArea to one small pixel. --- gui/ThemeEngine.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index e0563da711..78353a05de 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -1088,7 +1088,10 @@ void ThemeEngine::queueDDTextClip(TextData type, TextColor color, const Common:: area.clip(_screen.w, _screen.h); Common::Rect textArea = drawableTextArea; if (textArea.isEmpty()) textArea = clippingArea; - else textArea.clip(clippingArea); + else { + textArea.clip(clippingArea); + if (textArea.isEmpty()) textArea = Common::Rect(0, 0, 1, 1); // one small pixel should be invisible enough + } ThemeItemTextData *q = new ThemeItemTextData(this, _texts[type], _textColors[color], area, textArea, text, alignH, alignV, ellipsis, restoreBg, deltax); -- cgit v1.2.3 From a65682a828ff0213b60b983f0957c504ec2d2ec1 Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Fri, 22 Jul 2016 13:38:07 +0300 Subject: GUI: Fix warnings --- gui/ThemeEngine.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index 78353a05de..ac209d60a2 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -1449,6 +1449,9 @@ void ThemeEngine::drawDialogBackgroundClip(const Common::Rect &r, const Common:: case kDialogBackgroundDefault: queueDDClip(kDDDefaultBackground, r, clip); break; + case kDialogBackgroundNone: + // no op + break; } } -- cgit v1.2.3 From c74ba4652d497ddbdec4342029d94bc77387a705 Mon Sep 17 00:00:00 2001 From: Alexander Tkachev Date: Mon, 25 Jul 2016 16:37:44 +0600 Subject: GUI: Add "Paste" button in StorageWizardDialog It pastes clipboard contents as code into 8 fields of that dialog. (Clipboard support works with SDL2 only.) "Open URL" and "Paste" buttons are placed in the left column under the picture (because there is no room for 4 buttons in the bottom row). Commit also adds "dropbox.bmp", which is just a square 115x115 picture. Such pictures are would be used as Storages logos in that dialog. In lowres there is no left column, so all 4 buttons are in the same row. None of them are visible, because they are overflowed. Container has to be added to continue working on them. --- gui/ThemeEngine.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index ac209d60a2..e400e695db 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -61,6 +61,7 @@ const char *const ThemeEngine::kImageStopSmallButton = "stopbtn_small.bmp"; const char *const ThemeEngine::kImageEditSmallButton = "editbtn_small.bmp"; const char *const ThemeEngine::kImageSwitchModeSmallButton = "switchbtn_small.bmp"; const char *const ThemeEngine::kImageFastReplaySmallButton = "fastreplay_small.bmp"; +const char *const ThemeEngine::kImageDropboxLogo = "dropbox.bmp"; struct TextDrawData { const Graphics::Font *_fontPtr; -- cgit v1.2.3 From 091ff83ed66336fffada6453a34710214ac3576d Mon Sep 17 00:00:00 2001 From: Alexander Tkachev Date: Mon, 25 Jul 2016 19:25:49 +0600 Subject: GUI: Add Storage providers logos StorageWizardDialog now shows logo of the Storage being connected (in modern highres theme). --- gui/ThemeEngine.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'gui/ThemeEngine.cpp') diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp index e400e695db..96108bccce 100644 --- a/gui/ThemeEngine.cpp +++ b/gui/ThemeEngine.cpp @@ -62,6 +62,9 @@ const char *const ThemeEngine::kImageEditSmallButton = "editbtn_small.bmp"; const char *const ThemeEngine::kImageSwitchModeSmallButton = "switchbtn_small.bmp"; const char *const ThemeEngine::kImageFastReplaySmallButton = "fastreplay_small.bmp"; const char *const ThemeEngine::kImageDropboxLogo = "dropbox.bmp"; +const char *const ThemeEngine::kImageOneDriveLogo = "onedrive.bmp"; +const char *const ThemeEngine::kImageGoogleDriveLogo = "googledrive.bmp"; +const char *const ThemeEngine::kImageBoxLogo = "box.bmp"; struct TextDrawData { const Graphics::Font *_fontPtr; -- cgit v1.2.3