summaryrefslogtreecommitdiff
path: root/src/gui/widgets
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-02-08 00:49:41 +0300
committerAndrei Karas <akaras@inbox.ru>2012-02-08 00:49:41 +0300
commitff5e17ff14a78af31d9d23cd1dfdb5404f9a8fa9 (patch)
tree51a99a43eba0b09ca9e5f554b3676d0308685797 /src/gui/widgets
parent538261b13990ee02bbc62d9704233885b15cee04 (diff)
downloadmv-ff5e17ff14a78af31d9d23cd1dfdb5404f9a8fa9.tar.gz
mv-ff5e17ff14a78af31d9d23cd1dfdb5404f9a8fa9.tar.bz2
mv-ff5e17ff14a78af31d9d23cd1dfdb5404f9a8fa9.tar.xz
mv-ff5e17ff14a78af31d9d23cd1dfdb5404f9a8fa9.zip
Fix code style with new tool.
Diffstat (limited to 'src/gui/widgets')
-rw-r--r--src/gui/widgets/avatarlistbox.cpp2
-rw-r--r--src/gui/widgets/battletab.h3
-rw-r--r--src/gui/widgets/chattab.cpp2
-rw-r--r--src/gui/widgets/container.cpp2
-rw-r--r--src/gui/widgets/dropdown.h1
-rw-r--r--src/gui/widgets/inventoryfilter.cpp2
-rw-r--r--src/gui/widgets/layout.h4
-rw-r--r--src/gui/widgets/setupitem.cpp1
-rw-r--r--src/gui/widgets/setuptab.cpp2
-rw-r--r--src/gui/widgets/shoplistbox.cpp2
-rw-r--r--src/gui/widgets/slider.cpp1
-rw-r--r--src/gui/widgets/tablemodel.cpp1
-rw-r--r--src/gui/widgets/textfield.cpp22
-rw-r--r--src/gui/widgets/tradetab.h3
14 files changed, 19 insertions, 29 deletions
diff --git a/src/gui/widgets/avatarlistbox.cpp b/src/gui/widgets/avatarlistbox.cpp
index 2e3472515..822e71805 100644
--- a/src/gui/widgets/avatarlistbox.cpp
+++ b/src/gui/widgets/avatarlistbox.cpp
@@ -403,4 +403,4 @@ void AvatarListBox::optionChanged(const std::string &value)
mShowGender = config.getBoolValue("showgender");
else if (value == "showlevel")
mShowLevel = config.getBoolValue("showlevel");
-} \ No newline at end of file
+}
diff --git a/src/gui/widgets/battletab.h b/src/gui/widgets/battletab.h
index 8d85e739e..2a034a166 100644
--- a/src/gui/widgets/battletab.h
+++ b/src/gui/widgets/battletab.h
@@ -43,6 +43,3 @@ class BattleTab : public ChatTab
extern BattleTab *battleChatTab;
#endif
-
-
-
diff --git a/src/gui/widgets/chattab.cpp b/src/gui/widgets/chattab.cpp
index 6d5dfc9dd..018e35030 100644
--- a/src/gui/widgets/chattab.cpp
+++ b/src/gui/widgets/chattab.cpp
@@ -467,4 +467,4 @@ void ChatTab::addNewRow(std::string &line)
addRow(line);
}
mScrollArea->logic();
-} \ No newline at end of file
+}
diff --git a/src/gui/widgets/container.cpp b/src/gui/widgets/container.cpp
index 80028a62f..106112956 100644
--- a/src/gui/widgets/container.cpp
+++ b/src/gui/widgets/container.cpp
@@ -47,4 +47,4 @@ bool Container::safeRemove(gcn::Widget* widget)
}
}
return false;
-} \ No newline at end of file
+}
diff --git a/src/gui/widgets/dropdown.h b/src/gui/widgets/dropdown.h
index a769678ca..5896042fa 100644
--- a/src/gui/widgets/dropdown.h
+++ b/src/gui/widgets/dropdown.h
@@ -102,4 +102,3 @@ class DropDown : public gcn::DropDown
};
#endif // end DROPDOWN_H
-
diff --git a/src/gui/widgets/inventoryfilter.cpp b/src/gui/widgets/inventoryfilter.cpp
index 216c2bea0..515682cb6 100644
--- a/src/gui/widgets/inventoryfilter.cpp
+++ b/src/gui/widgets/inventoryfilter.cpp
@@ -58,4 +58,4 @@ void InventoryFilter::action(const gcn::ActionEvent &event)
{
(*iter)->action(event);
}
-} \ No newline at end of file
+}
diff --git a/src/gui/widgets/layout.h b/src/gui/widgets/layout.h
index 046d09b59..3c42554b6 100644
--- a/src/gui/widgets/layout.h
+++ b/src/gui/widgets/layout.h
@@ -37,8 +37,8 @@ class LayoutCell;
class ContainerPlacer
{
public:
- ContainerPlacer(gcn::Container *c = nullptr, LayoutCell *l = nullptr):
- mContainer(c), mCell(l)
+ ContainerPlacer(gcn::Container *c = nullptr, LayoutCell *lc = nullptr):
+ mContainer(c), mCell(lc)
{}
/**
diff --git a/src/gui/widgets/setupitem.cpp b/src/gui/widgets/setupitem.cpp
index 059b05ba2..56ce0a25a 100644
--- a/src/gui/widgets/setupitem.cpp
+++ b/src/gui/widgets/setupitem.cpp
@@ -455,7 +455,6 @@ void SetupItemIntTextField::apply(std::string eventName)
}
-
SetupItemLabel::SetupItemLabel(std::string text, std::string description,
SetupTabScroll *parent, bool separator) :
SetupItem(text, description, "", parent, "", "", true),
diff --git a/src/gui/widgets/setuptab.cpp b/src/gui/widgets/setuptab.cpp
index b3863c134..d4ae46eb8 100644
--- a/src/gui/widgets/setuptab.cpp
+++ b/src/gui/widgets/setuptab.cpp
@@ -31,4 +31,4 @@ SetupTab::SetupTab()
void SetupTab::externalUpdated()
{
-} \ No newline at end of file
+}
diff --git a/src/gui/widgets/shoplistbox.cpp b/src/gui/widgets/shoplistbox.cpp
index 71e373d70..ab6400149 100644
--- a/src/gui/widgets/shoplistbox.cpp
+++ b/src/gui/widgets/shoplistbox.cpp
@@ -191,4 +191,4 @@ void ShopListBox::mouseExited(gcn::MouseEvent& mouseEvent A_UNUSED)
return;
mItemPopup->hide();
-} \ No newline at end of file
+}
diff --git a/src/gui/widgets/slider.cpp b/src/gui/widgets/slider.cpp
index ed667e194..c6b57858c 100644
--- a/src/gui/widgets/slider.cpp
+++ b/src/gui/widgets/slider.cpp
@@ -298,4 +298,3 @@ void Slider::mouseExited(gcn::MouseEvent& event A_UNUSED)
{
mHasMouse = false;
}
-
diff --git a/src/gui/widgets/tablemodel.cpp b/src/gui/widgets/tablemodel.cpp
index 5216fb89c..bc5d2ead6 100644
--- a/src/gui/widgets/tablemodel.cpp
+++ b/src/gui/widgets/tablemodel.cpp
@@ -173,4 +173,3 @@ int StaticTableModel::getHeight() const
{
return mColumns * mHeight;
}
-
diff --git a/src/gui/widgets/textfield.cpp b/src/gui/widgets/textfield.cpp
index 4dba2eb57..e207b0613 100644
--- a/src/gui/widgets/textfield.cpp
+++ b/src/gui/widgets/textfield.cpp
@@ -208,29 +208,29 @@ void TextField::keyPressed(gcn::KeyEvent &keyEvent)
}
else if (!mMaximum || mText.size() < mMaximum)
{
- int l;
+ int len;
if (val < 128)
- l = 1; // 0xxxxxxx
+ len = 1; // 0xxxxxxx
else if (val < 0x800)
- l = 2; // 110xxxxx 10xxxxxx
+ len = 2; // 110xxxxx 10xxxxxx
else if (val < 0x10000)
- l = 3; // 1110xxxx 10xxxxxx 10xxxxxx
+ len = 3; // 1110xxxx 10xxxxxx 10xxxxxx
else
- l = 4; // 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx
+ len = 4; // 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx
char buf[4];
- for (int i = 0; i < l; ++i)
+ for (int i = 0; i < len; ++ i)
{
- buf[i] = static_cast<char>(val >> (6 * (l - i - 1)));
+ buf[i] = static_cast<char>(val >> (6 * (len - i - 1)));
if (i > 0)
buf[i] = static_cast<char>((buf[i] & 63) | 128);
}
- if (l > 1)
- buf[0] |= static_cast<char>(255 << (8 - l));
+ if (len > 1)
+ buf[0] |= static_cast<char>(255 << (8 - len));
- mText.insert(mCaretPosition, std::string(buf, buf + l));
- mCaretPosition += l;
+ mText.insert(mCaretPosition, std::string(buf, buf + len));
+ mCaretPosition += len;
}
}
diff --git a/src/gui/widgets/tradetab.h b/src/gui/widgets/tradetab.h
index 06add3ee0..44922c31a 100644
--- a/src/gui/widgets/tradetab.h
+++ b/src/gui/widgets/tradetab.h
@@ -46,6 +46,3 @@ class TradeTab : public ChatTab
extern TradeTab *tradeChatTab;
#endif
-
-
-