From ba997be747666c74c46c734cb636a8de84c582b3 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 17 Dec 2011 16:42:27 +0300 Subject: Move target cursors to themes. Remove old unused target cursors. --- data/graphics/CMakeLists.txt | 9 --------- data/graphics/Makefile.am | 9 --------- data/graphics/gui/CMakeLists.txt | 12 ++++++------ data/graphics/gui/Makefile.am | 12 ++++++------ data/graphics/gui/target-cursor-blue-l.png | Bin 23803 -> 0 bytes data/graphics/gui/target-cursor-blue-m.png | Bin 18439 -> 0 bytes data/graphics/gui/target-cursor-blue-s.png | Bin 8353 -> 0 bytes data/graphics/gui/target-cursor-in-range-l.png | Bin 0 -> 23803 bytes data/graphics/gui/target-cursor-in-range-m.png | Bin 0 -> 18439 bytes data/graphics/gui/target-cursor-in-range-s.png | Bin 0 -> 8353 bytes data/graphics/gui/target-cursor-normal-l.png | Bin 0 -> 25586 bytes data/graphics/gui/target-cursor-normal-m.png | Bin 0 -> 17950 bytes data/graphics/gui/target-cursor-normal-s.png | Bin 0 -> 8361 bytes data/graphics/gui/target-cursor-red-l.png | Bin 25586 -> 0 bytes data/graphics/gui/target-cursor-red-m.png | Bin 17950 -> 0 bytes data/graphics/gui/target-cursor-red-s.png | Bin 8361 -> 0 bytes data/graphics/target-cursor-in-range-l.png | Bin 23803 -> 0 bytes data/graphics/target-cursor-in-range-m.png | Bin 18439 -> 0 bytes data/graphics/target-cursor-in-range-s.png | Bin 8353 -> 0 bytes data/graphics/target-cursor-normal-l.png | Bin 25586 -> 0 bytes data/graphics/target-cursor-normal-m.png | Bin 17950 -> 0 bytes data/graphics/target-cursor-normal-s.png | Bin 8361 -> 0 bytes packaging/windows/setup.nsi | 2 -- src/actorsprite.cpp | 6 +++--- 24 files changed, 15 insertions(+), 35 deletions(-) delete mode 100644 data/graphics/gui/target-cursor-blue-l.png delete mode 100644 data/graphics/gui/target-cursor-blue-m.png delete mode 100644 data/graphics/gui/target-cursor-blue-s.png create mode 100644 data/graphics/gui/target-cursor-in-range-l.png create mode 100644 data/graphics/gui/target-cursor-in-range-m.png create mode 100644 data/graphics/gui/target-cursor-in-range-s.png create mode 100644 data/graphics/gui/target-cursor-normal-l.png create mode 100644 data/graphics/gui/target-cursor-normal-m.png create mode 100644 data/graphics/gui/target-cursor-normal-s.png delete mode 100644 data/graphics/gui/target-cursor-red-l.png delete mode 100644 data/graphics/gui/target-cursor-red-m.png delete mode 100644 data/graphics/gui/target-cursor-red-s.png delete mode 100644 data/graphics/target-cursor-in-range-l.png delete mode 100644 data/graphics/target-cursor-in-range-m.png delete mode 100644 data/graphics/target-cursor-in-range-s.png delete mode 100644 data/graphics/target-cursor-normal-l.png delete mode 100644 data/graphics/target-cursor-normal-m.png delete mode 100644 data/graphics/target-cursor-normal-s.png diff --git a/data/graphics/CMakeLists.txt b/data/graphics/CMakeLists.txt index a46ccfd0e..5a9b0f65b 100644 --- a/data/graphics/CMakeLists.txt +++ b/data/graphics/CMakeLists.txt @@ -1,12 +1,3 @@ ADD_SUBDIRECTORY(gui) ADD_SUBDIRECTORY(images) ADD_SUBDIRECTORY(sprites) - -SET (FILES - target-cursor-in-range-l.png - target-cursor-in-range-m.png - target-cursor-in-range-s.png - target-cursor-normal-l.png - target-cursor-normal-m.png - target-cursor-normal-s.png - ) diff --git a/data/graphics/Makefile.am b/data/graphics/Makefile.am index d2f93f584..c0e91d050 100644 --- a/data/graphics/Makefile.am +++ b/data/graphics/Makefile.am @@ -1,16 +1,7 @@ graphicsdir = $(pkgdatadir)/data/graphics -graphics_DATA = \ - target-cursor-in-range-l.png \ - target-cursor-in-range-m.png \ - target-cursor-in-range-s.png \ - target-cursor-normal-l.png \ - target-cursor-normal-m.png \ - target-cursor-normal-s.png - EXTRA_DIST = \ - $(graphics_DATA) \ CMakeLists.txt SUBDIRS = gui images sprites diff --git a/data/graphics/gui/CMakeLists.txt b/data/graphics/gui/CMakeLists.txt index 2c6e4b933..aba42b39c 100644 --- a/data/graphics/gui/CMakeLists.txt +++ b/data/graphics/gui/CMakeLists.txt @@ -33,12 +33,12 @@ SET (FILES tab.png tab_hilight.png tabselected.png - target-cursor-blue-l.png - target-cursor-blue-m.png - target-cursor-blue-s.png - target-cursor-red-l.png - target-cursor-red-m.png - target-cursor-red-s.png + target-cursor-in-range-l.png + target-cursor-in-range-m.png + target-cursor-in-range-s.png + target-cursor-normal-l.png + target-cursor-normal-m.png + target-cursor-normal-s.png unknown-item.png vscroll_down_default.png vscroll_down_highlight.png diff --git a/data/graphics/gui/Makefile.am b/data/graphics/gui/Makefile.am index 388d01663..7fb82f545 100644 --- a/data/graphics/gui/Makefile.am +++ b/data/graphics/gui/Makefile.am @@ -36,12 +36,12 @@ gui_DATA = \ tab.png \ tab_hilight.png \ tabselected.png \ - target-cursor-blue-l.png \ - target-cursor-blue-m.png \ - target-cursor-blue-s.png \ - target-cursor-red-l.png \ - target-cursor-red-m.png \ - target-cursor-red-s.png \ + target-cursor-in-range-l.png \ + target-cursor-in-range-m.png \ + target-cursor-in-range-s.png \ + target-cursor-normal-l.png \ + target-cursor-normal-m.png \ + target-cursor-normal-s.png \ unknown-item.png \ vscroll_down_default.png \ vscroll_down_highlight.png \ diff --git a/data/graphics/gui/target-cursor-blue-l.png b/data/graphics/gui/target-cursor-blue-l.png deleted file mode 100644 index 77cdf4b6d..000000000 Binary files a/data/graphics/gui/target-cursor-blue-l.png and /dev/null differ diff --git a/data/graphics/gui/target-cursor-blue-m.png b/data/graphics/gui/target-cursor-blue-m.png deleted file mode 100644 index c0107357a..000000000 Binary files a/data/graphics/gui/target-cursor-blue-m.png and /dev/null differ diff --git a/data/graphics/gui/target-cursor-blue-s.png b/data/graphics/gui/target-cursor-blue-s.png deleted file mode 100644 index 3e81c75de..000000000 Binary files a/data/graphics/gui/target-cursor-blue-s.png and /dev/null differ diff --git a/data/graphics/gui/target-cursor-in-range-l.png b/data/graphics/gui/target-cursor-in-range-l.png new file mode 100644 index 000000000..77cdf4b6d Binary files /dev/null and b/data/graphics/gui/target-cursor-in-range-l.png differ diff --git a/data/graphics/gui/target-cursor-in-range-m.png b/data/graphics/gui/target-cursor-in-range-m.png new file mode 100644 index 000000000..c0107357a Binary files /dev/null and b/data/graphics/gui/target-cursor-in-range-m.png differ diff --git a/data/graphics/gui/target-cursor-in-range-s.png b/data/graphics/gui/target-cursor-in-range-s.png new file mode 100644 index 000000000..3e81c75de Binary files /dev/null and b/data/graphics/gui/target-cursor-in-range-s.png differ diff --git a/data/graphics/gui/target-cursor-normal-l.png b/data/graphics/gui/target-cursor-normal-l.png new file mode 100644 index 000000000..76d2101b1 Binary files /dev/null and b/data/graphics/gui/target-cursor-normal-l.png differ diff --git a/data/graphics/gui/target-cursor-normal-m.png b/data/graphics/gui/target-cursor-normal-m.png new file mode 100644 index 000000000..e2ab79c29 Binary files /dev/null and b/data/graphics/gui/target-cursor-normal-m.png differ diff --git a/data/graphics/gui/target-cursor-normal-s.png b/data/graphics/gui/target-cursor-normal-s.png new file mode 100644 index 000000000..09195f440 Binary files /dev/null and b/data/graphics/gui/target-cursor-normal-s.png differ diff --git a/data/graphics/gui/target-cursor-red-l.png b/data/graphics/gui/target-cursor-red-l.png deleted file mode 100644 index 76d2101b1..000000000 Binary files a/data/graphics/gui/target-cursor-red-l.png and /dev/null differ diff --git a/data/graphics/gui/target-cursor-red-m.png b/data/graphics/gui/target-cursor-red-m.png deleted file mode 100644 index e2ab79c29..000000000 Binary files a/data/graphics/gui/target-cursor-red-m.png and /dev/null differ diff --git a/data/graphics/gui/target-cursor-red-s.png b/data/graphics/gui/target-cursor-red-s.png deleted file mode 100644 index 09195f440..000000000 Binary files a/data/graphics/gui/target-cursor-red-s.png and /dev/null differ diff --git a/data/graphics/target-cursor-in-range-l.png b/data/graphics/target-cursor-in-range-l.png deleted file mode 100644 index 77cdf4b6d..000000000 Binary files a/data/graphics/target-cursor-in-range-l.png and /dev/null differ diff --git a/data/graphics/target-cursor-in-range-m.png b/data/graphics/target-cursor-in-range-m.png deleted file mode 100644 index c0107357a..000000000 Binary files a/data/graphics/target-cursor-in-range-m.png and /dev/null differ diff --git a/data/graphics/target-cursor-in-range-s.png b/data/graphics/target-cursor-in-range-s.png deleted file mode 100644 index 3e81c75de..000000000 Binary files a/data/graphics/target-cursor-in-range-s.png and /dev/null differ diff --git a/data/graphics/target-cursor-normal-l.png b/data/graphics/target-cursor-normal-l.png deleted file mode 100644 index 76d2101b1..000000000 Binary files a/data/graphics/target-cursor-normal-l.png and /dev/null differ diff --git a/data/graphics/target-cursor-normal-m.png b/data/graphics/target-cursor-normal-m.png deleted file mode 100644 index e2ab79c29..000000000 Binary files a/data/graphics/target-cursor-normal-m.png and /dev/null differ diff --git a/data/graphics/target-cursor-normal-s.png b/data/graphics/target-cursor-normal-s.png deleted file mode 100644 index 09195f440..000000000 Binary files a/data/graphics/target-cursor-normal-s.png and /dev/null differ diff --git a/packaging/windows/setup.nsi b/packaging/windows/setup.nsi index ebb2002a1..9767cf685 100644 --- a/packaging/windows/setup.nsi +++ b/packaging/windows/setup.nsi @@ -268,8 +268,6 @@ Section "Core files (required)" SecCore File "${SRCDIR}\README.txt" SetOutPath "$INSTDIR\data\fonts" File "${SRCDIR}\data\fonts\*.ttf" - SetOutPath "$INSTDIR\data\graphics" - File "${SRCDIR}\data\graphics\*.png" SetOutPath "$INSTDIR\data\graphics\gui" File "${SRCDIR}\data\graphics\gui\*.png" File "${SRCDIR}\data\graphics\gui\*.xml" diff --git a/src/actorsprite.cpp b/src/actorsprite.cpp index 2a92cf506..a0fafbbf9 100644 --- a/src/actorsprite.cpp +++ b/src/actorsprite.cpp @@ -437,7 +437,7 @@ static const char *cursorSize(int size) void ActorSprite::initTargetCursor() { - static std::string targetCursorFile = "graphics/target-cursor-%s-%s.png"; + static std::string targetCursorFile = "target-cursor-%s-%s.png"; static int targetWidths[NUM_TC] = {44, 62, 82}; static int targetHeights[NUM_TC] = {35, 44, 60}; @@ -479,8 +479,8 @@ void ActorSprite::loadTargetCursor(const std::string &filename, if (size < TC_SMALL || size >= NUM_TC) return; - ResourceManager *resman = ResourceManager::getInstance(); - ImageSet *currentImageSet = resman->getImageSet(filename, width, height); + ImageSet *currentImageSet = Theme::getImageSetFromTheme( + filename, width, height); if (!currentImageSet) { -- cgit v1.2.3-70-g09d2