From f0f674830faa8b32a4bb53b79d45972989cc5a7b Mon Sep 17 00:00:00 2001 From: dborth Date: Sat, 17 Oct 2009 00:15:20 +0000 Subject: [PATCH] libwiigui documentation updates --- src/platform/wii/libwiigui/gui.h | 10 ++--- src/platform/wii/libwiigui/gui_element.cpp | 42 -------------------- src/platform/wii/libwiigui/gui_imagedata.cpp | 6 +-- src/platform/wii/libwiigui/gui_sound.cpp | 6 +-- 4 files changed, 11 insertions(+), 53 deletions(-) diff --git a/src/platform/wii/libwiigui/gui.h b/src/platform/wii/libwiigui/gui.h index c6694a7..8aa8b70 100644 --- a/src/platform/wii/libwiigui/gui.h +++ b/src/platform/wii/libwiigui/gui.h @@ -133,7 +133,7 @@ class GuiSound //!\param s Pointer to the sound data //!\param l Length of sound data //!\param t Sound format type (SOUND_PCM or SOUND_OGG) - GuiSound(const u8 * s, int l, int t); + GuiSound(const u8 * s, s32 l, int t); //!Destructor ~GuiSound(); //!Start sound playback @@ -292,8 +292,8 @@ class GuiElement //!\param c Clickable void SetClickable(bool c); //!Sets whether or not the element is holdable - //!\param c Holdable - void SetHoldable(bool d); + //!\param h Holdable + void SetHoldable(bool h); //!Gets the element's current state //!\return state int GetState(); @@ -592,7 +592,7 @@ class GuiText : public GuiElement //!\param c Font color GuiText(const char * t, int s, GXColor c); //!\overload - //!\Assumes SetPresets() has been called to setup preferred text attributes + //!Assumes SetPresets() has been called to setup preferred text attributes //!\param t Text GuiText(const char * t); //!Destructor @@ -614,7 +614,7 @@ class GuiText : public GuiElement void SetFontSize(int s); //!Sets the maximum width of the drawn texture image //!\param w Maximum width - void SetMaxWidth(int width); + void SetMaxWidth(int w); //!Enables/disables text scrolling //!\param s Scrolling on/off void SetScroll(int s); diff --git a/src/platform/wii/libwiigui/gui_element.cpp b/src/platform/wii/libwiigui/gui_element.cpp index 6641997..5bb2c88 100644 --- a/src/platform/wii/libwiigui/gui_element.cpp +++ b/src/platform/wii/libwiigui/gui_element.cpp @@ -70,11 +70,6 @@ GuiElement * GuiElement::GetParent() return parentElement; } -/** - * Get the left position of the GuiElement. - * @see SetLeft() - * @return Left position in pixel. - */ int GuiElement::GetLeft() { int x = 0; @@ -105,11 +100,6 @@ int GuiElement::GetLeft() return x + xoffset; } -/** - * Get the top position of the GuiElement. - * @see SetTop() - * @return Top position in pixel. - */ int GuiElement::GetTop() { int y = 0; @@ -180,33 +170,16 @@ int GuiElement::GetMaxY() return ymax; } -/** - * Get the width of the GuiElement. - * @see SetWidth() - * @return Width of the GuiElement. - */ int GuiElement::GetWidth() { return width; } -/** - * Get the height of the GuiElement. - * @see SetHeight() - * @return Height of the GuiElement. - */ int GuiElement::GetHeight() { return height; } -/** - * Set the width and height of the GuiElement. - * @param[in] Width Width in pixel. - * @param[in] Height Height in pixel. - * @see SetWidth() - * @see SetHeight() - */ void GuiElement::SetSize(int w, int h) { @@ -214,21 +187,11 @@ void GuiElement::SetSize(int w, int h) height = h; } -/** - * Get visible. - * @see SetVisible() - * @return true if visible, false otherwise. - */ bool GuiElement::IsVisible() { return visible; } -/** - * Set visible. - * @param[in] Visible Set to true to show GuiElement. - * @see IsVisible() - */ void GuiElement::SetVisible(bool v) { visible = v; @@ -557,11 +520,6 @@ void GuiElement::Draw() { } -/** - * Check if a position is inside the GuiElement. - * @param[in] x X position in pixel. - * @param[in] y Y position in pixel. - */ bool GuiElement::IsInside(int x, int y) { if(x > this->GetLeft() && x < (this->GetLeft()+width) diff --git a/src/platform/wii/libwiigui/gui_imagedata.cpp b/src/platform/wii/libwiigui/gui_imagedata.cpp index 6781be8..fb6ef21 100644 --- a/src/platform/wii/libwiigui/gui_imagedata.cpp +++ b/src/platform/wii/libwiigui/gui_imagedata.cpp @@ -13,16 +13,16 @@ /** * Constructor for the GuiImageData class. */ -GuiImageData::GuiImageData(const u8 * img) +GuiImageData::GuiImageData(const u8 * i) { data = NULL; width = 0; height = 0; - if(img) + if(i) { PNGUPROP imgProp; - IMGCTX ctx = PNGU_SelectImageFromBuffer(img); + IMGCTX ctx = PNGU_SelectImageFromBuffer(i); if(!ctx) return; diff --git a/src/platform/wii/libwiigui/gui_sound.cpp b/src/platform/wii/libwiigui/gui_sound.cpp index b3213e7..a272274 100644 --- a/src/platform/wii/libwiigui/gui_sound.cpp +++ b/src/platform/wii/libwiigui/gui_sound.cpp @@ -13,10 +13,10 @@ /** * Constructor for the GuiSound class. */ -GuiSound::GuiSound(const u8 * snd, s32 len, int t) +GuiSound::GuiSound(const u8 * s, s32 l, int t) { - sound = snd; - length = len; + sound = s; + length = l; type = t; voice = -1; volume = 100;