summaryrefslogtreecommitdiffstats
path: root/src/ui
diff options
context:
space:
mode:
authorkrzys-h <krzys_h@interia.pl>2013-09-28 11:13:45 +0200
committerkrzys-h <krzys_h@interia.pl>2013-09-28 11:13:45 +0200
commitd70d31acc1753a6edda69727448834e6e1a07886 (patch)
tree0fb2fbd4d58fdc9efb8c658c1f1b4fb4e67c2efb /src/ui
parent39866db50275c4cf1fd4cc1cc6deb2d1573e24d8 (diff)
downloadcolobot-d70d31acc1753a6edda69727448834e6e1a07886.tar.gz
colobot-d70d31acc1753a6edda69727448834e6e1a07886.tar.bz2
colobot-d70d31acc1753a6edda69727448834e6e1a07886.zip
Fix for #232 - Images in SatCom
Only images, icons still don't work
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/edit.cpp8
-rw-r--r--src/ui/edit.h4
2 files changed, 6 insertions, 6 deletions
diff --git a/src/ui/edit.cpp b/src/ui/edit.cpp
index 6fd1735..a187688 100644
--- a/src/ui/edit.cpp
+++ b/src/ui/edit.cpp
@@ -1144,7 +1144,7 @@ void CEdit::DrawImage(Math::Point pos, std::string name, float width,
float dp;
std::string filename;
- filename = GetProfile().GetUserBasedPath(name, "diagram") + ".png";
+ filename = GetProfile().GetUserBasedPath(name, "../icons") + ".png";
m_engine->SetTexture(filename);
m_engine->SetState(Gfx::ENG_RSTATE_NORMAL);
@@ -1426,7 +1426,7 @@ void CEdit::FreeImage()
for (int i = 0 ; i < m_imageTotal; i++ )
{
- filename = GetProfile().GetUserBasedPath(m_image[i].name, "diagram") + ".png";
+ filename = GetProfile().GetUserBasedPath(m_image[i].name, "../icons") + ".png";
m_engine->DeleteTexture(filename);
}
}
@@ -1436,7 +1436,7 @@ void CEdit::FreeImage()
void CEdit::LoadImage(std::string name)
{
std::string filename;
- filename = GetProfile().GetUserBasedPath(name, "diagram") + ".png";
+ filename = GetProfile().GetUserBasedPath(name, "../icons") + ".png";
m_engine->LoadTexture(filename);
}
@@ -1653,7 +1653,7 @@ bool CEdit::ReadText(std::string filename, int addSize)
m_image[iIndex].width = iWidth*0.75f;
m_text[j] = static_cast<char>(iIndex++); // as an index into m_image
- m_format[j] = static_cast<unsigned char>(Gfx::FONT_MASK_IMAGE);
+ m_format[j] = Gfx::FONT_MASK_IMAGE;
j ++;
}
}
diff --git a/src/ui/edit.h b/src/ui/edit.h
index acdf72c..9484fc8 100644
--- a/src/ui/edit.h
+++ b/src/ui/edit.h
@@ -89,7 +89,7 @@ enum OperUndo
struct ImageLine
{
- //! name of the image (without diagram \)
+ //! name of the image (without icons/)
std::string name;
//! vertical offset (v texture)
float offset;
@@ -101,7 +101,7 @@ struct ImageLine
struct HyperLink
{
- //! text file name (without help \)
+ //! text file name (without help/)
std::string name;
//! name of the marker
std::string marker;