summaryrefslogtreecommitdiffhomepage
path: root/Stars45/ListBox.cpp
diff options
context:
space:
mode:
authorAki <please@ignore.pl>2022-01-30 17:41:24 +0100
committerAki <please@ignore.pl>2022-01-30 17:41:24 +0100
commit51657e10769faa2617d546a06c42e4c62a19bb50 (patch)
tree688ad8b61ac02e50974684b9b7d3f886fb469e5f /Stars45/ListBox.cpp
parentdb987e23d5dd33a5db8764743facbb906ac22b0f (diff)
downloadstarshatter-51657e10769faa2617d546a06c42e4c62a19bb50.zip
starshatter-51657e10769faa2617d546a06c42e4c62a19bb50.tar.gz
starshatter-51657e10769faa2617d546a06c42e4c62a19bb50.tar.bz2
Removed trailing whitespace all over the place
Diffstat (limited to 'Stars45/ListBox.cpp')
-rw-r--r--Stars45/ListBox.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/Stars45/ListBox.cpp b/Stars45/ListBox.cpp
index 2992393..a4782c7 100644
--- a/Stars45/ListBox.cpp
+++ b/Stars45/ListBox.cpp
@@ -157,7 +157,7 @@ int ListBoxItem::operator <=(const ListBoxItem& item) const
if (listbox && listbox == item.listbox) {
int sort_column = listbox->GetSortColumn() - 1;
int sort_criteria = listbox->GetSortCriteria();
-
+
if (sort_column == -1) {
switch (sort_criteria) {
case ListBox::LIST_SORT_NUMERIC_DESCENDING:
@@ -204,7 +204,7 @@ int ListBoxItem::operator == (const ListBoxItem& item) const
if (listbox && listbox == item.listbox) {
int sort_column = listbox->GetSortColumn() - 1;
int sort_criteria = listbox->GetSortCriteria();
-
+
if (sort_column == -1) {
switch (sort_criteria) {
case ListBox::LIST_SORT_NUMERIC_DESCENDING:
@@ -384,7 +384,7 @@ ListBox::DrawContent(const Rect& ctrl_rect)
}
else {
text_rect.Deflate(2,0);
- DrawText(item->text.data(),
+ DrawText(item->text.data(),
item->text.length(),
text_rect,
GetColumnAlign(column)|DT_SINGLELINE);
@@ -580,7 +580,7 @@ void ListBox::SetItemText(int index, int column, const char* text)
if (index >= 0 && index < items.size()) {
ListBoxItem* item = items[index];
-
+
column--;
if (column >= 0 && column < columns.size()-1) {
while (column >= item->subitems.size()) {
@@ -602,7 +602,7 @@ DWORD ListBox::GetItemData(int index, int column)
if (index >= 0 && index < items.size()) {
ListBoxItem* item = items[index];
-
+
column--;
if (column >= 0 && column < item->subitems.size())
return item->subitems[column]->data;
@@ -620,7 +620,7 @@ void ListBox::SetItemData(int index, int column, DWORD data)
if (index >= 0 && index < items.size()) {
ListBoxItem* item = items[index];
-
+
column--;
if (column >= 0 && column < columns.size()-1) {
while (column >= item->subitems.size()) {
@@ -642,7 +642,7 @@ Bitmap* ListBox::GetItemImage(int index, int column)
if (index >= 0 && index < items.size()) {
ListBoxItem* item = items[index];
-
+
column--;
if (column >= 0 && column < item->subitems.size())
return item->subitems[column]->image;
@@ -660,7 +660,7 @@ void ListBox::SetItemImage(int index, int column, Bitmap* img)
if (index >= 0 && index < items.size()) {
ListBoxItem* item = items[index];
-
+
column--;
if (column >= 0 && column < columns.size()-1) {
while (column >= item->subitems.size()) {
@@ -1141,7 +1141,7 @@ int ListBox::OnLButtonDown(int x, int y)
int next_col_start = 0;
int max_column = columns.size()-1;
int column;
-
+
for (column = 0; column < max_column; column++) {
next_col_start += GetColumnWidth(column);