Skip to content

Commit

Permalink
Merge branch 'release/4.7.3'
Browse files Browse the repository at this point in the history
  • Loading branch information
ccomeaux committed May 15, 2014
2 parents 057f25e + 4ca9808 commit e9e8f54
Show file tree
Hide file tree
Showing 82 changed files with 916 additions and 708 deletions.
4 changes: 2 additions & 2 deletions BoardGameGeek/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.boardgamegeek"
android:installLocation="auto"
android:versionCode="35"
android:versionName="4.7.2" >
android:versionCode="36"
android:versionName="4.7.3" >

<uses-sdk
android:minSdkVersion="8"
Expand Down
Binary file removed BoardGameGeek/res/drawable-hdpi/knob.png
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed BoardGameGeek/res/drawable-mdpi/chart_up.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/chart_up_orange.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/chart_up_yellow.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/cloud_comment.png
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/database.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/database_pressed.png
Binary file not shown.
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/empty_calendar.png
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/key.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/key_orange.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/key_yellow.png
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed BoardGameGeek/res/drawable-mdpi/tools.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/tools_pressed.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/tools_selected.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/users.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/users_pressed.png
Binary file not shown.
Binary file removed BoardGameGeek/res/drawable-mdpi/users_selected.png
Diff not rendered.
8 changes: 0 additions & 8 deletions BoardGameGeek/res/drawable/home_btn_buddies.xml

This file was deleted.

8 changes: 0 additions & 8 deletions BoardGameGeek/res/drawable/home_btn_collection.xml

This file was deleted.

8 changes: 0 additions & 8 deletions BoardGameGeek/res/drawable/home_btn_forums.xml

This file was deleted.

8 changes: 0 additions & 8 deletions BoardGameGeek/res/drawable/home_btn_hotness.xml

This file was deleted.

8 changes: 0 additions & 8 deletions BoardGameGeek/res/drawable/home_btn_plays.xml

This file was deleted.

8 changes: 0 additions & 8 deletions BoardGameGeek/res/drawable/home_btn_settings.xml

This file was deleted.

8 changes: 0 additions & 8 deletions BoardGameGeek/res/drawable/home_btn_signin.xml

This file was deleted.

6 changes: 3 additions & 3 deletions BoardGameGeek/res/layout/dialog_slider_filter.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@
android:layout_height="wrap_content"
android:gravity="center" />

<com.boardgamegeek.ui.widget.DualSliderView
android:id="@+id/slider_filter_slider"
<FrameLayout
android:id="@+id/slider_filter_rangeseekbar_container"
android:layout_width="fill_parent"
android:layout_height="0dp" />
android:layout_height="wrap_content" />

<CheckBox
android:id="@+id/slider_filter_checkbox"
Expand Down
15 changes: 2 additions & 13 deletions BoardGameGeek/res/layout/row_drawer.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,22 +20,11 @@
android:layout_height="wrap_content"
android:orientation="horizontal" >

<ImageView
android:id="@android:id/icon"
android:layout_width="@dimen/thumbnail_list_size"
android:layout_height="@dimen/thumbnail_list_size"
android:paddingRight="@dimen/padding_extra"
android:scaleType="fitCenter"
tools:ignore="ContentDescription" />

<TextView
android:id="@android:id/text1"
style="@style/Text.Primary"
style="@style/Text.DrawerItem"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fontFamily="sans-serif"
android:gravity="center_vertical"
android:textIsSelectable="false" />
android:layout_height="match_parent" />
</LinearLayout>

</LinearLayout>
2 changes: 1 addition & 1 deletion BoardGameGeek/res/values-normal/layout.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>

<item name="row_forumthread" type="layout">@layout/row_forumthread</item>
<item name="row_forumthread" type="layout">@layout/row_forumthread_wide</item>

</resources>
7 changes: 7 additions & 0 deletions BoardGameGeek/res/values-v11/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,11 @@

<style name="Theme.bgglight.Dialog" parent="@android:style/Theme.Holo.Dialog" />

<style name="Text.DrawerItem" parent="Text.Huge">
<item name="android:gravity">center_vertical</item>
<item name="android:paddingLeft">@dimen/padding_extra</item>
<item name="android:paddingRight">@dimen/padding_extra</item>
<item name="android:textIsSelectable">false</item>
</style>

</resources>
8 changes: 8 additions & 0 deletions BoardGameGeek/res/values-v16/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,12 @@
<item name="android:fontFamily">sans-serif-light</item>
</style>

<style name="Text.DrawerItem" parent="Text.Huge">
<item name="android:fontFamily">sans-serif</item>
<item name="android:gravity">center_vertical</item>
<item name="android:paddingLeft">@dimen/padding_extra</item>
<item name="android:paddingRight">@dimen/padding_extra</item>
<item name="android:textIsSelectable">false</item>
</style>

</resources>
6 changes: 6 additions & 0 deletions BoardGameGeek/res/values/layout.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>

<item name="row_forumthread" type="layout">@layout/row_forumthread</item>

</resources>
22 changes: 9 additions & 13 deletions BoardGameGeek/res/values/strings_prefs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@
<string name="pref_advanced_debug_inserts">Debug</string>
<string name="pref_advanced_debug_inserts_off">Leave this off if you\'re not crashing</string>
<string name="pref_advanced_debug_inserts_on">Next time the app crashes, please send a report. Thanks for helping us debug!</string>
<string name="pref_advanced_polls">Polls</string>
<string name="pref_advanced_polls_off">Polls will no longer work, but hopefully the crashes will stop</string>
<string name="pref_advanced_polls">Game polls</string>
<string name="pref_advanced_polls_off">Polls for games will no longer work, but hopefully the crashes will stop. (This has nothing to do with polls in forums - those will never work.)</string>
<string name="pref_advanced_polls_on">Leave this on if you\'re not crashing</string>
<string name="pref_advanced_notify_errors">Notify errors</string>
<string name="pref_advanced_notify_errors_off">Leave this off if you\'re not crashing</string>
Expand All @@ -79,6 +79,13 @@
<string name="pref_about_app_name_and_version"><![CDATA[<b>BoardGameGeek</b> <font color="#888888">%s</font>]]></string>
<string name="pref_about_body">
<![CDATA[<h4>What\'s New?</h4>
<h5>4.7.3</h5>
<ul>
<li>Fix crashes in forums and ordering players</li>
<li>Change look and feel of navigation drawer</li>
<li>Modernize the look of the slider in the filter dialog</li>
<li>Show the collection properly when adding a shortcut</li>
</ul>
<h5>4.7.2</h5>
<ul>
<li>Fix crash when viewing buddy collection</li>
Expand All @@ -92,18 +99,7 @@
<ul>
<li>No more crashes</li>
</ul>
<h5>4.7</h5>
<ul>
<li>Sticky headers and bigger images in lists</li>
<li>Set a collection view as the default</li>
<li>When adding players to a play, a list of most common players is displayed, enabling quicker entry</li>
<li>Consider a play started within 2 hours of the previous play ending as part of the same session, and copy the location and players to the new play</li>
<li>Calculates your games played h-index</li>
<li>Ability to add a color to a game</li>
<li>Option to show the full date/time in the forums (under Settings > Advanced)</li>
<li>When syncing, remove games not in your collection if they haven\'t been viewed in 3 days</li>
<li>When enabling custom player order, prompt to remove the existing starting positions</li>
<li>Miscellaneous fixes and improvements</li>
<li><a href="https://code.google.com/p/boardgamegeek/wiki/ReleaseNotes">What was new in previous versions?</a></li>
</ul>
<br/>
Expand Down
10 changes: 10 additions & 0 deletions BoardGameGeek/res/values/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,10 @@
<item name="android:textSize">16sp</item>
</style>

<style name="Text.Huge">
<item name="android:textSize">20sp</item>
</style>

<style name="Text.Primary" parent="Text.Big">
<item name="android:textStyle">bold</item>
<item name="android:lineSpacingMultiplier">0.9</item>
Expand Down Expand Up @@ -98,6 +102,12 @@

<style name="Text.CheckboxLabel"></style>

<style name="Text.DrawerItem" parent="Text.Huge">
<item name="android:gravity">center_vertical</item>
<item name="android:paddingLeft">@dimen/padding_extra</item>
<item name="android:paddingRight">@dimen/padding_extra</item>
</style>

<style name="RowContainer">
<item name="android:gravity">center</item>
<item name="android:minHeight">?android:attr/listPreferredItemHeight</item>
Expand Down
4 changes: 4 additions & 0 deletions BoardGameGeek/res/xml/preference_about.xml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@
android:dialogMessage="@string/pref_about_picasso_license"
android:summary="Apache License 2.0"
android:title="Picasso" />
<com.boardgamegeek.pref.LicensePreference
android:dialogMessage="A slider widget for Android allowing to set a minimum and maximum value on a numerical range."
android:summary="Apache License 2.0"
android:title="range-seek-bar" />
<com.boardgamegeek.pref.LicensePreference
android:dialogMessage="@string/pref_about_slh_license"
android:summary="Apache License 2.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ private void setDisplayText(Resources r) {
if (mExact) {
range = r.getString(R.string.exactly) + " ";
}
if (mExact || mMin == mMax) {
if (mMin == mMax) {
range += String.valueOf(mMax);
} else {
range += String.valueOf(mMin) + "-" + String.valueOf(mMax);
Expand All @@ -60,10 +60,10 @@ private void setSelection() {

if (mExact) {
selection(Games.MIN_PLAYERS + "=? AND " + Games.MAX_PLAYERS + "=?");
selectionArgs(maxValue, maxValue);
selectionArgs(minValue, maxValue);
} else {
selection(Games.MIN_PLAYERS + "<=? AND (" + Games.MAX_PLAYERS + ">=?" + " OR " + Games.MAX_PLAYERS
+ " IS NULL)");
+ " IS NULL)");
selectionArgs(minValue, maxValue);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public class GeekRatingSortData extends CollectionSortData {
public GeekRatingSortData(Context context) {
super(context);
mOrderByClause = Collection.SORT_BY_RATING;
mDescriptionId = R.string.rating;
mDescriptionId = R.string.menu_collection_sort_rating;
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public class MyRatingSortData extends CollectionSortData {
public MyRatingSortData(Context context) {
super(context);
mOrderByClause = getClause(Collection.RATING, true);
mDescriptionId = R.string.rating;
mDescriptionId = R.string.menu_collection_sort_myrating;
}

@Override
Expand Down
10 changes: 5 additions & 5 deletions BoardGameGeek/src/com/boardgamegeek/model/HotGame.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,13 @@ public void writeToParcel(Parcel dest, int flags) {
dest.writeInt(YearPublished);
}

public static final Parcelable.Creator<Forum> CREATOR = new Parcelable.Creator<Forum>() {
public Forum createFromParcel(Parcel in) {
return new Forum(in);
public static final Parcelable.Creator<HotGame> CREATOR = new Parcelable.Creator<HotGame>() {
public HotGame createFromParcel(Parcel in) {
return new HotGame(in);
}

public Forum[] newArray(int size) {
return new Forum[size];
public HotGame[] newArray(int size) {
return new HotGame[size];
}
};
}
26 changes: 17 additions & 9 deletions BoardGameGeek/src/com/boardgamegeek/model/Play.java
Original file line number Diff line number Diff line change
Expand Up @@ -229,23 +229,31 @@ public Player getPlayerAtSeat(int seat) {
return null;
}

public void reorderPlayers(int fromSeat, int toSeat) {
public boolean reorderPlayers(int fromSeat, int toSeat) {
if (arePlayersCustomSorted()) {
return;
return false;
}
Player player = getPlayerAtSeat(fromSeat);
if (player == null) {
return false;
}
player.setSeat(Player.SEAT_UNKNOWN);
if (fromSeat > toSeat) {
for (int i = fromSeat - 1; i >= toSeat; i--) {
getPlayerAtSeat(i).setSeat(i + 1);
}
} else {
for (int i = fromSeat + 1; i <= toSeat; i++) {
getPlayerAtSeat(i).setSeat(i - 1);
try {
if (fromSeat > toSeat) {
for (int i = fromSeat - 1; i >= toSeat; i--) {
getPlayerAtSeat(i).setSeat(i + 1);
}
} else {
for (int i = fromSeat + 1; i <= toSeat; i++) {
getPlayerAtSeat(i).setSeat(i - 1);
}
}
} catch (NullPointerException e) {
return false;
}
player.setSeat(toSeat);
sortPlayers();
return true;
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ public void execute(RemoteExecutor executor, Account account, SyncResult syncRes
RemoteBggHandler handler = new RemoteGameHandler(System.currentTimeMillis());
String url = new GameUrlBuilder(gameIds).stats().build();
executor.executeGet(url, handler);
SyncService.hIndex(executor.getContext());
// syncResult.stats.numUpdates += handler.getCount();
}
} finally {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ public void execute(RemoteExecutor executor, Account account, SyncResult syncRes
// syncResult.stats.numUpdates += handler.getCount();
}
}
SyncService.hIndex(executor.getContext());
}
} finally {
LOGI(TAG, "...complete!");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ public void execute(RemoteExecutor executor, Account account, SyncResult syncRes
accountManager
.setUserData(account, SyncService.TIMESTAMP_COLLECTION_PARTIAL, String.valueOf(startTime));
}
SyncService.hIndex(executor.getContext());
} finally {
LOGI(TAG, "...complete!");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ public void execute(RemoteExecutor executor, Account account, SyncResult syncRes
accountManager
.setUserData(account, SyncService.TIMESTAMP_COLLECTION_PARTIAL, String.valueOf(startTime));
}
SyncService.hIndex(executor.getContext());
} finally {
LOGI(TAG, "...complete!");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ public void execute(RemoteExecutor executor, Account account, SyncResult syncRes
String url = builder.build();
executor.safelyExecuteGet(url, handler);
// syncResult.stats.numUpdates += handler.getCount();
SyncService.hIndex(executor.getContext());
}
} finally {
LOGI(TAG, "...complete!");
Expand Down
1 change: 0 additions & 1 deletion BoardGameGeek/src/com/boardgamegeek/service/SyncGame.java
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ public void execute(RemoteExecutor executor, Context context) {
}
String url = new GameUrlBuilder(mGameId).stats().build();
executor.safelyExecuteGet(url, handler);
SyncService.hIndex(context);
LOGI(TAG, "Synced Game " + mGameId);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ public void execute(RemoteExecutor executor, Context context) {
RemoteCollectionHandler handler = new RemoteCollectionHandler(System.currentTimeMillis(), true, true);
String url = new CollectionUrlBuilder(account.name).gameId(mGameId).showPrivate().stats().build();
executor.safelyExecuteGet(url, handler);
SyncService.hIndex(context);
LOGI(TAG, "Synced collection for game " + mGameId);
}
}
Loading

0 comments on commit e9e8f54

Please sign in to comment.