Commit graph

10308 commits

Author SHA1 Message Date
Eric House
604119f99b stub out GCMIntentService for d variant
Somehow the d variant was crashing without the WAKELOCK permission, the
OS having invokes something GCM-related. This should ensure nothing
GCM-related can ever happen.
2017-09-26 07:01:55 -07:00
Eric House
6fa01eb971 move GCM-related permissions into new manifest
Create an AndroidManifest.xml specific for the xw4 variant, and move the
GCM-related permissions (including WakeLock) into it.
2017-09-25 06:17:44 -07:00
Eric House
fd7f564e11 add debug menu to copy git info to clipboard
Makes it easier to find out what the diffs were.
2017-09-24 14:40:31 -07:00
Eric House
096aa3bd0f make GCM_SENDER_ID empty for xw4d variant build
This seems to fix that app, when built by me where GCM_SENDER_ID's set
in the environment, being a battery hog. Apparently google's code
doesn't handle being passed the wrong senderID very well.
2017-09-24 14:30:59 -07:00
Eric House
9bdf43a89e remove duplicated BuildConfig entry 2017-09-22 06:55:02 -07:00
Eric House
5dc9327d31 record current git-diff in assets 2017-09-22 06:46:19 -07:00
Eric House
618ee89add fix crash drawing game timer
It's outside the normal begin_/end_draw flow and so cairo wasn't set up
as expected.
2017-09-20 07:26:26 -07:00
Eric House
592a6429d4 up changelog and version strings 2017-09-20 06:40:42 -07:00
Eric House
39efbaa7f5 fix timer-draw NPE due to race condition
use runOnUiThread()....
2017-09-19 22:09:57 -07:00
Eric House
a328221b63 up version codes for new release
I somehow screwed up the last release, but google got the apk so
requires me to change the version number.
2017-09-19 07:46:17 -07:00
Eric House
dc29321b28 change strings for new release 2017-09-13 08:06:08 -07:00
Eric House
e98c25a81a fix crash by removing assert I didn't need
Looks like what I was worried about wasn't an issue.
2017-09-13 07:39:07 -07:00
Eric House
baf549189c add compile-time option for forcing square board
Disabled. Needed it for a test.
2017-09-13 07:38:22 -07:00
Eric House
ae25c6e014 fix list item breakage: no inputType for TextView
I'd added inputType="text" everywhere I added maxLines="1" but it turns
out that breaks touches being handled at least on some devices. And it
makes no sense to have an inputType for something user can't put into.
2017-09-12 07:56:40 -07:00
Eric House
058d3a7828 try to fix travis: copy over .enc file 2017-09-11 06:47:59 -07:00
Eric House
8efd608ac2 fold in (as diff, not merge) travis config 2017-09-11 06:16:47 -07:00
Eric House
54997f6db2 more EditText fixing 2017-09-07 07:51:57 -07:00
Eric House
2de54a2535 fix script for a gradle world 2017-09-07 07:45:33 -07:00
Eric House
d87a1ca7a8 fix EditText so monkey can't abuse it
Several EditText fields are configured so monkey breaks things, e.g. by
entering too much text in the default player name config. Fix. This
probably won't impact users but it lets the monkey tests move on to
other things that might.
2017-09-07 07:36:16 -07:00
Eric House
f161de2977 make menu consistent 2017-09-07 06:15:17 -07:00
Eric House
1ee5afd5cf add inputType=text to singleline EditTexts
Turns out the maxLine="1" thing needs this accompaniment or it'll let
you add carriage returns, as adb monkey found.
2017-09-07 06:13:14 -07:00
Eric House
6866887438 include last commit in change notes 2017-09-05 19:23:21 -07:00
Eric House
8971837d22 fix crash on Samsung Galaxy Note 3 running 4.4
Can't repro on Nexus emulator running 4.4 nor on Samsung running 4.4.4,
but the reporter says this fixes it. And from reading it appears
expecting older devices to load Material themes without an AppCompat
library is wrong.
2017-09-05 19:17:02 -07:00
Eric House
f5e66463f9 up release strings for new version 2017-09-03 14:15:43 -07:00
naofum
406ffca333 Translated using Weblate (Japanese)
Currently translated at 73.8% (545 of 738 strings)
2017-09-03 14:15:26 -07:00
Eric House
51ca1777e2 make the have-chat icon green 2017-09-03 13:28:37 -07:00
Eric House
4549c397ae cleanup
don't check standalone games for chat messages
2017-09-03 10:38:54 -07:00
Eric House
2735144515 mark games with unread chat 2017-09-02 12:12:39 -07:00
Eric House
2616891608 remove/replace deprecated singleLine element 2017-09-02 12:12:39 -07:00
Eric House
a10dd6a314 make game sort order clearer and easier to modify
For the ORDER BY clause that governs how games are displayed within a
group, use a static string built from a list of clauses that are then
easy to move up and down. Add clause that moves games with unread chat
to the top. Another commit will modify the display so it's clear why
it's there.
2017-09-02 12:12:39 -07:00
Eric House
5ed9d2c6aa remove dead code 2017-09-02 11:24:58 -07:00
Eric House
1c3b5564b5 use same red/green for expiry as for net status
Slightly less glaring; slightly more consistency.
2017-09-01 08:12:38 -07:00
Eric House
e97dd26e6f fix missing "game in room NNNN" in games list
Looks like sometimes the TextField was GONE
2017-08-31 21:21:54 -07:00
Bernard Massot
e24f7bdba8 Translated using Weblate (French)
Currently translated at 91.1% (673 of 738 strings)
2017-08-31 21:21:54 -07:00
Eric House
a6d8708abc sort unconnected games to top of list 2017-08-31 20:07:40 -07:00
Eric House
79b0d38c0c tweak changelog 2017-08-30 06:30:25 -07:00
Eric House
8489d1401f only try to put up Wait/Invite alert once
Bring back the test for being null, and add an additional one via a new
boolean iVar that we haven't tried posting it already. On some devices
there's enough of a lag that the is-null test passes several times
before the first makeDialog() call, leading to a cascade of attempts to
create that hangs the UI. The test's needed, but only once should be
start the process.
2017-08-29 07:33:15 -07:00
Eric House
077159b8c4 save commitID in instanceState
When the back stack is restored commit() is not called, so the fragment
needs to save it. Without this 0 is passed to popBackStack() and
everything's dismissed, not just the one fragment.
2017-08-29 07:31:37 -07:00
Eric House
741dbf2bed fix finish() to close a specific fragment
Rather than just pop whatever's on top of the back stack, which might be
the alert whose listener called finish(), use saved commit() ids to pop
down to the fragment itself. This feels like a risky change, and it's
tested only by back-button-dismissing the Wait alert in an unconnected
game in BoardDelegate, so needs some bake time.
2017-08-29 07:10:04 -07:00
Eric House
bb4c5502c8 save commit id in fragment 2017-08-29 07:03:52 -07:00
Eric House
270df00692 use new API to offer to hide buttons
When SDK >= 19 there's an API to tell if a listview is full enough to
require scrolling. So use that, rather than the raw count of games, to
decide whether to offer new users to hide the new game buttons.
2017-08-28 07:12:10 -07:00
Eric House
db658edc67 don't add to queue once it's stopped
No point in adding something if we're not going to process it.
2017-08-28 07:06:57 -07:00
Eric House
671d345377 remove most of xw4dbg's AndroidManifest.xml
What's here is merged with the main one, so no point in duplicating and
it's just a pain to maintain. Remove as much as possible that's not
unique to the debug variant (crashlytics and wifidirect, basically.)
2017-08-27 15:55:31 -07:00
Eric House
58f828c187 up version strings and changelog 2017-08-27 15:49:57 -07:00
Eric House
54be99b635 remove logging 2017-08-27 15:49:35 -07:00
Eric House
5914ad8a1d include ActionPair in serialization of DlgState
Oops. Debug build assertion showed I was leaving an infrequently used
field out of serialization, adn then required that that object be
Serializable and implement equals() to pass more tests.
2017-08-27 11:40:26 -07:00
Eric House
9231224eea explicitly use Theme.Material as app theme
Fixed Samsung having made a white actionbar default and so my menubar
icons becoming invisible.
2017-08-27 10:12:37 -07:00
Eric House
ff415640fd sync variants' AndroidManifest.xml files 2017-08-26 11:02:27 -07:00
Eric House
24a38c8f46 cleanup connection status display text
Get rid of treating 0 as a legit date (1970 being illegit). Tweak
formatting. It's not perfect, but few people see it so we'll see how it
goes during development.
2017-08-24 06:58:53 -07:00
Eric House
1a36f3286b ignore generated files 2017-08-22 07:52:15 -07:00
Eric House
33f80fbefd up version strings for new release 2017-08-16 07:34:03 -07:00
Eric House
f7d4d6b637 sort by versionCode, then by file age
revert a bit, dropping use of git revision and repo to provide an
order. Instead use aapt (which is an ubuntu package now) to pull the
version code and appID from .apk files, order by versionCode, and
secondarily by file mod time.
2017-08-16 07:29:17 -07:00
Eric House
19c7543eb3 make finding most recent apk based on git revision
Auto-update was based on my manually setting what the newest is. Better
to use the git revision stored in the .apk, or failing that (later) in
the file name, to determine "age". This is all based on forcing a linear
order on git commits, but at least at the granularity of releases that
should be ok.
2017-08-14 22:40:07 -07:00
Eric House
bb846060e9 always add "self" choice to invite-by-relay-id list
Poorly integrated: you can delete it only to have it come back, but
send-to-self is just a debugging thing anyway.
2017-08-14 07:52:18 -07:00
Eric House
f795ae6de6 use same string for both download menuitems
Mistake was putting "download more languages" at the bottom of list of
wordlists in one language. Having separate strings is a bigger change,
and in context just "Download more" works in both cases. Change name of
string so translators will notice.
2017-08-14 07:18:16 -07:00
Eric House
eb34294679 fix failure to create game after downloading dict
Wasn't setting the necessary iVar...
2017-08-14 06:49:05 -07:00
Eric House
af48fb850d update strings for new release 2017-08-13 19:37:29 -07:00
Eric House
2f6c6b0644 fix ClassCastException: 0 isn't a long; 0L is 2017-08-13 12:59:58 -07:00
Eric House
ae86378bcd don't assert on DEBUG: too frequent
I need to fix this, but crashing all the time isn't the answer.
2017-08-11 06:25:25 -07:00
Eric House
ddfa3a567f Merge remote-tracking branch 'weblate/android_translate' into android_branch 2017-08-08 21:57:04 -07:00
Eric House
ba8a5ceeb6 up version for new release 2017-08-07 21:48:50 -07:00
Eric House
635fbed719 catch and drop illegal state exception
By inspection based on report to Play store.
2017-08-06 14:08:33 -07:00
Eric House
93a8aa77bf fix NPE
It might make sense to have default value of m_params be 0-length
array....
2017-08-03 07:13:32 -07:00
Eric House
6cee0c5bca check that all params are serializable
DEBUG builds only.
2017-08-02 07:20:48 -07:00
Eric House
455b6e79f0 use TextUtils.equals in new equals() overrides 2017-08-02 07:09:38 -07:00
Eric House
4ec930d53c fix array out-of-bounds exception 2017-08-01 22:22:44 -07:00
Eric House
bb367acab3 don't pass unserializable in params[]
Was, in rarely seen case, passing an object that couldn't be
serialized. Instead pass a few of its constituents than can, and
reconstitute using them.
2017-08-01 22:21:47 -07:00
Eric House
62dd6c12f7 remove unnecessary parameter 2017-08-01 22:03:47 -07:00
Eric House
c927dbef54 fix equals() implementation 2017-08-01 21:37:02 -07:00
Eric House
9a394b2541 comment out code with RELAYINVITE_SUPPORTED
Relay-invite code may never be released, so wrap it in compile-time test
that'll get it stripped.
2017-08-01 07:33:37 -07:00
Eric House
101c2ff8f2 fix problems with params[] serialization
Was passing through DlgState params a number of classes that weren't
serializable or that didn't have equals() methods required for DEBUG
assertions to pass. Added versions of equals() that just call super in
non-DEBUG case since it's a lot of code and isn't required except for
testing. (Serialization of course is.)
2017-08-01 07:28:17 -07:00
Eric House
d55d9573e4 fix some bundling/serialization problems
Now that params[] are being bundled all objects passed that way must be
serializeable. And as long as I'm asserting bundle success using
equals() the objects being serialized must implement it.
2017-07-29 20:59:00 -07:00
Eric House
80cc12fc79 up version strings and change list for new release 2017-07-29 20:21:23 -07:00
Eric House
e2c46963d8 fix crash (by inspection) with complete parcel save
I wasn't saving/restoring params[] Object array with DlgState, and under
circumstances I can't reproduce that could cause a null object
dereference I was via the Play store. So added a test case that failed
for DlgState instances that have non-null params arrays, and fixed that.
2017-07-28 07:37:57 -07:00
Dener Luiz da Silva
af7cf8edc0 Translated using Weblate (Portuguese)
Currently translated at 53.7% (396 of 737 strings)
2017-07-26 21:46:17 +02:00
Eric House
ca93f808f3 change invite alert track/dismiss logic
Attempt to fix invite alert sticking around after game connection
finishes, which resulted from the variable pointing to the alert having
been set to null. So stop setting it in onDismiss listener. I think
trying to track it via an iVar is a mistake, that dismiss by tag or
somesuch is the right way to go. But my dialog fragment code isn't up to
that yet.
2017-07-26 07:21:27 -07:00
Eric House
c6a72b63ee make relay invite record editable 2017-07-25 07:48:54 -07:00
Eric House
32c6a5e114 don't enable remove button when nothing's checked
Copy from SMS inviter code. Really should be moving that into the
superclass.
2017-07-23 17:50:47 -07:00
Eric House
a71d60db63 implement deletion; save with new serialization util
Add new Utils methods that turn Serializable objects into B64-encoded
Strings, and vice versa. Use in place of existing code, and use anew to
store the array of DeviceID records. Implement the "Delete checked" button.
2017-07-23 17:31:59 -07:00
Eric House
7eb9458a78 get invite-by-relayid working again
In Dbg version only (with enabling boolean moved to BuildConfig.)
Currently crashes when first used, and recipient can't always connect to
relay until app rebooted. And of course there are still open questions
like how to populate the list -- how user learns the deviceID of an
opponent.
2017-07-23 16:45:14 -07:00
Eric House
bd250cfe1e log before asserting 2017-07-19 07:16:18 -07:00
Eric House
41529a584c add recent changes to changelog 2017-07-19 06:35:26 -07:00
Eric House
d057de0fd3 add comment reminder of proguard problem 2017-07-19 06:27:56 -07:00
Eric House
72c624b251 track resends for each comms type
Was previously a "global" so that a resend over SMS might delay a resend
for relay games. Since communication problems tend to be
comms-type-specific that's dumb.
2017-07-19 06:26:11 -07:00
Eric House
52a1ccd4dc tweak comments 2017-07-19 06:16:22 -07:00
Eric House
64014944f3 finish: using java's base64 en/decoder from java
Added a wrapper function since for compatibility with the jni's encoding
the flags matter and need to be the same everywhere. Or at least there
should be no chance of their getting changed.
2017-07-13 07:40:28 -07:00
Eric House
94dca807ef use a singlton rather than one Time per object
De-serializing a Time formatter wasn't going well post-proguard, but it
was a dumb way to do it anyway when only one object is needed.
2017-07-13 07:20:24 -07:00
Eric House
fb91ba8608 fix (by inspection) store-reported NPE 2017-07-12 08:14:42 -07:00
Eric House
4f989c7a3e start using built-in base64 stuff
As a first step, use mine and android's and assert results are the
same. Note using built-in Base64 class requires moving the min android
version from 7 to 8.
2017-07-12 08:02:52 -07:00
Eric House
589929b3b2 enable proguard for debug builds
Copy config file into the right place, turn it on for debug builds, and
fix compile-time complaints by adding -keep clauses. Resulting builds
seem to work (after a few minutes in emulator only) except that net
status icon taps crash at first (eventually recovering somehow) likely
because of problems with base64 en/decoding which goes through jni.
2017-07-12 07:16:57 -07:00
Eric House
75488aefc0 use same SMS resend backoff for debug as release 2017-07-10 06:51:45 -07:00
Eric House
c8beefaafe tweak network status icon
Get rid of black background of center icon, instead running the green or
red all the way to the middle. For better contrast make the green and
red darker and the non-active arrows white.
2017-07-10 06:49:02 -07:00
Eric House
924dc1b37f remove assert
Looks like my theory was right. Logging is more than enough.
2017-07-05 07:53:41 -07:00
Eric House
15f50dc82a fix game config for rotation and connvia changes
The debug-only settings for disabling individual conn types weren't
kept in sync with which types were enabled, and that set of types was
lost on rotation. Fixed (including keeping the disableds across rotations.)
2017-06-30 06:34:24 -07:00
Eric House
b9d6b05d87 tweak logging 2017-06-29 07:28:15 -07:00
Eric House
d6bbccb773 let caller deal with result of message resend
Use a new interface to let caller of resendAllIf() know how many
messages were resent. If none, a new timer might not be called for.
2017-06-28 08:24:33 -07:00
Eric House
bdc1f5ff51 when game full drop message but don't assert
I'm seeing assertions when a game gets into a state I don't fully
understand: host receives messages that need a channelNo assigned but
the game's full. With luck they're duplicates and can be ignored,
because that's all I can do.
2017-06-28 07:04:15 -07:00
Eric House
33838e6a14 don't crash when crashlytics didn't get built in correctly 2017-06-27 07:34:04 -07:00
Eric House
d454ffb3e8 up changelog/strings for release 2017-06-22 07:12:51 -07:00
Eric House
4e101862a6 get rid of old standin for missing contact name
Since it's now possible to add a name for an SMS contact added manually,
don't assuming a missing name means it was added manually. Just leave
blank if not provided.
2017-06-21 07:59:22 -07:00
Eric House
e3e7add5a9 fix (I hope) script for harvesting jni sigs
I made these changes a while ago then stashed them. They worked when I
needed them then, and seem to work now, but I haven't verified now so
don't trust 'em too far. :-)
2017-06-20 22:05:39 -07:00
Eric House
a16cc8e648 replace Crittercism with Crashlytics, suckily
Crittercism is dropping free support of FOSS apps, so I'm dropping
it. Unfortunatly integration isn't as clean: so far at least I haven't
figured out how to make it possible for others to build the 'd' variant,
which includes Crashlytics, without their having a Fabric API key.
2017-06-20 21:48:40 -07:00
Eric House
6de5d307b3 add name field to manual sms contacts entry 2017-06-20 19:35:38 -07:00
Eric House
b33df6b222 reset SMSResend timer on new data only
Resetting it on every ACK etc meant it happened forever at the most
frequent interval, at least on devices that have both sides of a game,
which is my usual test setup.
2017-06-20 19:19:03 -07:00
Eric House
e6454070a6 remove an oft-firing assert
It's definitely happening, and disruptive though debug-only. So remove
to be tracked down eventually.
2017-06-20 19:17:23 -07:00
Eric House
e3a8bef3cb add new param
It's not the case that forcing send and showing UI go together.
2017-06-20 07:49:01 -07:00
Eric House
0b2920102b tweak chat layout; use better timestamp format 2017-06-20 07:47:32 -07:00
Eric House
3aefa3a566 don't make sound/notify on standalone game moves
I'm finding the robot move beeps annoying. If others aren't maybe a
preference would be better. We'll see.
2017-06-16 19:24:04 -07:00
Eric House
7f48267397 save non-destructive changes on "Play game" button
In game config, when the play game button's hit and the changes pending don't
"matter" (require reset), apply them. The motiviation is to allow
setting the "disableds" and immediately launching a game via the button,
but I think it's the right thing to do anyway. Needs testing.
2017-06-16 19:18:30 -07:00
Eric House
7bae112077 add timer to resend sms data messages
Deal with occasional droppage of SMS data messages by running a
timer (via AlarmManager) with backoff that resends any pending moves for
games connected via SMS. Successful receipt of SMS data resets the backoff.
2017-06-16 18:56:22 -07:00
Eric House
0b0a50bd5c add timestamp to chat messages, db and display
On send, add current seconds to message. Store and display in android
code. Display layout needs work.
2017-06-10 11:36:45 -07:00
Eric House
6f0fb66a0d fix three-year-old huuuuge memory leak
Hadn't run Valgrind in a while. There's another too, but much smaller
and harder to track down.
2017-06-07 08:07:42 -07:00
Eric House
f06e7bdd98 don't drop duplicate reconnect
When Android client is backgrounded with a game playing (BoardActivity
on top) then brought to front again it fails to reconnect to relay
because it didn't disconnect and the relay thinks it's still there. The
right fix is in making the java code do the right thing (complete
disconnect), but it seems harmless to just honor the reconnect in this
case. Doesn't even cause leaks, per valgrind.
2017-06-06 06:27:58 -07:00
Eric House
59285aa9f4 cleanup 2017-06-06 05:46:27 -07:00
Eric House
f85f7c41be add cmdline options to generate single-abi .so
Part of getting split builds going. I think.
2017-06-06 05:45:31 -07:00
Eric House
41683f95a7 improve activity lifecycle logging 2017-06-05 07:36:47 -07:00
Eric House
5c893127de remove constants from build.gradle
cleanup, iterating over built-in data rather than my hard-coded VARIANTS
and BUILDS arrays, which now go away. Renamed obj- and libs- directories
to better fit the variables the system provides.
2017-06-01 07:41:51 -07:00
Eric House
f49aac71cf get rid of <a> -- sucks in webview 2017-05-31 20:22:13 -07:00
Eric House
c53616fd82 wrap code in if(DEBUG) 2017-05-27 13:26:57 -07:00
Eric House
9644f40659 add ui for disabling comms send and receive
Add DEBUG-builds-only UI at the bottom of GameConfig for turning on the
comms feature dropping outgoing or incoming messages. The idea's to use
this to reproduce and fix stalls. There's a noticable slowdown opening
the GameConfig fragment, but it should all be no-op in a release build.
2017-05-26 07:49:38 -07:00
Eric House
95ec573169 save disabled booleans in comms state
I want them persisted since the GTK UI doesn't make sense and they
should effect background sends and receives too.
2017-05-26 07:30:42 -07:00
Eric House
a815c466c9 up strings for new release 2017-05-25 20:13:00 -07:00
Eric House
7164ab92f6 make FirstRunDialog a DialogFragment
It was disappearing when the device rotated. Using the same
XWDialogFragment mechanism as everything else fixes that.
2017-05-25 19:58:04 -07:00
Eric House
b6665a15c4 double-check to avoid crash (by observation)
Chasing a rare play-store-reported JNI crash: test for a null ptr in C
and assert/test in Java.
2017-05-25 07:10:49 -07:00
Eric House
d584c30a43 fix (by inspection) three Play store crashes
One race condition between BT threads; two edge cases around dialog
fragments, where I've left DEBUG build asserts in place.
2017-05-24 21:27:18 -07:00
Eric House
935932f440 don't try to upgrade fdroid builds
Add BuildConfig boolean that's true when a gradle property is passed in
from the fdroid metadata/build file. Test when putting together upgrade
state and omit app info when it's true, same as if from Play store.
2017-05-24 20:16:07 -07:00
Eric House
d58c601bf3 include git revision in assets/ dir (.gitignore it)
Makes it easier to see what's been built into an apk if the file's name
has changed.
2017-05-24 07:09:11 -07:00
Eric House
340a559eb7 don't report fdroid builds as dirty
F-droid build system modifies git-controlled files so no build will ever
be clean. So look for a -P property and if that's set don't use the
--dirty flag when capturing the git revision. Requires a change to the
fdroid metadata to pass that property.
2017-05-24 06:49:09 -07:00
Eric House
222655ba58 get rid of background for expander buttons
In the gameslist view the expander buttons had a visible rectangular
background. Now that's transparent so they look like the rest.
2017-05-23 19:03:29 -07:00
Eric House
3c650ce762 fix xw4d build (shortening more xw4dbg) 2017-05-23 19:03:29 -07:00
Eric House
acf7097fda sign release apks outside of gradle
My sign-inside-gradle is an uncommon trick and unnecessary. Better to
follow the old convention of using jarsigner and zipalign.
2017-05-23 19:03:19 -07:00
Eric House
ef2da21bbe xw4dbg -> xw4d: tired of typing the extra letters
Rename the debug variant and make it work. appID stays the same and so
no longer matches. Gradle allows that.
2017-05-23 06:37:31 -07:00
Eric House
4ad7e171f6 keep db open throughout
Years back what I read said you opened and closed the database around
every query. Now I'm reading differently, that the OS will close it for
you on app shutdown and that it's ok to just leave it open. Trying
that after a few minutes on one device looks ok. Will need to test the
heck out of it, especially on older OS versions, before ship.
2017-05-18 21:20:21 -07:00
Eric House
8a4563e8ee up version strings 2017-05-18 06:53:03 -07:00
Eric House
a834a8170a catch IllegalStateException
Play store reports crashes but stack crawl doesn't tell me where
from. So try catching the exception and on debug builds logging what
dialog is responsible.
2017-05-18 06:37:58 -07:00
Eric House
7f4d8b1a44 remove firing assertion (per Play store)
Looks like clock skew or maybe even a timezone issue (I'm not doing
enough research :-) is causing an assert. Just drop the notification
instead.
2017-05-18 06:19:25 -07:00
Eric House
098de83b04 fix assertion: don't pass bundle as alert param
it's not serializable, and more's the point is already being saved
across rotations in the delegate, so just use that.
2017-05-09 07:02:12 -07:00
Eric House
a6d5f409cb include translations in changelog 2017-05-08 20:47:08 -07:00
Eric House
055f54611d catch NPE Play console reports thrown by OS
No clue why this might be happening, but perhaps catching and dropping
will prevent a bad user experience?
2017-05-07 17:06:26 -07:00
Eric House
c3bfbfb956 up version strings and changelog for release 2017-05-07 16:27:40 -07:00
Eric House
f8077785bc cleanup: remove comments and unnecessary ivar 2017-05-07 16:25:18 -07:00
Eric House
9b88279212 remove need for file
app_name.xml's contents are in generated file, so just use that. Saves a
change on each release.
2017-05-07 16:05:36 -07:00
Eric House
c637fd1eee remove not-again explanation for public rooms
When those became an advanced feature I added a warning for upgrading
players who'd miss them. That was long ago, and the warning was only
supposed to last a release or two.
2017-05-06 21:05:42 -07:00
Eric House
579a7ae5cb change emacs compile-command for java files (generated) 2017-05-06 20:59:17 -07:00
Eric House
3c2d36c5d4 Merge branch 'android_branch' into android_translate 2017-05-05 07:20:36 -07:00
Eric House
309622b592 put back a couple of words -- not dirty! 2017-05-05 06:48:52 -07:00
Eric House
252db56bba update English wordlists to bowdlerized 2017-05-04 22:48:15 -07:00
Eric House
8752432de3 add ability to filter out "dirty" words
If a Makefile defines a dirty word list then a new python script is
invoked to filter for and remove those words as the dict is being
built. So far I have for English only, which makes sense because only
English wordlists are built-in on Android and Google's rating system
cares only about what's built in.
2017-05-04 22:45:27 -07:00
Eric House
ed781b36b5 remove dismissDialog() and removeDialog()
One's a no-op the one place it was used, and the other's not used at all
2017-05-03 07:10:26 -07:00
Eric House
77a5d9c217 remove onConfigurationChanged(); no longer called
Removing from AndroidManifest meant the overridden method is no longer
called, so remove it and the code it calls.
2017-05-03 07:01:21 -07:00
Eric House
14dd3b4950 remove one-release-only explanation
Stuff explaining change only makes sense the first release after it's
added. So remove.
2017-05-03 06:53:39 -07:00
Eric House
c6d3870365 remove dead file 2017-05-03 06:51:16 -07:00
naofum
41f8072182 Translated using Weblate (Japanese)
Currently translated at 74.4% (549 of 737 strings)
2017-05-02 12:45:40 +02:00
Eric House
8588756556 fix assertion fail
It's legit for makeDialog() to fail when e.g. committing a turn while
board and chat are visible. So remove assertion.
2017-05-01 07:37:18 -07:00
Bernard Massot
2d3c8f799b Translated using Weblate (French)
Currently translated at 89.0% (656 of 737 strings)
2017-04-30 21:44:59 +02:00
Eric House
f18b3c61bf cleanup: get rid of old dialog stuff
showDialog() goes away except for PrefsActivity which can't do
fragments. Move stuff required by PrefsDelegate into it from
DelegateBase since no other subclasses does old-style Dialogs
any more. Remove a bunch of stuff from DlgDelegate, e.g. saving
state, that no longer gets used.
2017-04-27 21:37:48 -07:00
Eric House
a1c92b6957 cleanup from review of changes 2017-04-27 21:37:27 -07:00
Eric House
6caff930e7 Merge branch 'android_branch' into android_translate 2017-04-26 19:18:50 -07:00
Eric House
7a64b6066f Merge branch 'android_translate' of git://git.weblate.org/xwords into android_translate 2017-04-26 19:16:56 -07:00
Eric House
c3f0ed692c more useful log statement 2017-04-26 06:35:48 -07:00
Eric House
6fbb701dbe post from activityResult to avoid transaction error
Was getting crash with "Can not perform this action after
onSaveInstanceState". This lets the back stack get back into shape so it
can put up another alert.
2017-04-25 07:37:12 -07:00
Eric House
52ea395ad6 put invite/wait alert on back stack
Add to DldID the ability to specify whether dialog fragments bearing
that id go on the back stack. Set INVITE alerts (only) to use that
mechanism. Having them on the back stack seems to be required by their
buttons being hacked to not dismiss them, which in turn is required
because I want them to stick around underneath other alerts their
buttons launch.
2017-04-20 22:06:49 -07:00
Eric House
e12c303f0c fix NPE 2017-04-20 07:19:06 -07:00
Eric House
3dd5ac34fd don't [re]show rematch alert on rotation
on onCreate() test for bundle being null, and only in that case put up
the alert. Keeps it from piling up on rotations.
2017-04-19 21:24:00 -07:00
Eric House
97c459d708 fix format exception in logging 2017-04-19 07:15:21 -07:00
Eric House
22e0c9f1b1 fix assertion by running on ui thread
And since all calls to showDialogFragment do that now no need to wrap calls.
2017-04-18 07:48:52 -07:00
Eric House
2453de0128 consolidate dual-pane settings
Get rid of explicit enable-dualpane boolean pref, instead relying on the
three way default/force-phone/force-tablet pref. Offer to change that
rather than the former in BoardDelegate when run on upgrade. Move the
prefs setting from Debug to Appearance since it's "real" now.
2017-04-18 07:26:45 -07:00
Eric House
f88b438a81 get rid of configChanges altogether
Recent recommendations are not to attempt to handle it myself, so don't
and we'll see how it goes. And unify notions of tablet and enabling
dual-pane: a device that isn't dual-pane should not be using the new
single-activity stuff at all.
2017-04-18 06:47:53 -07:00
Eric House
269fceddf2 cleanup around posting alerts; skip back-stack
Had to disable use of the back-stack for DialogFragments, though that
means I can't prevent duplicates from stacking up (esp. in the
pathological robot-vs-robot case, but also just when I rotate the device
while a "rematch" alert is up.) The problem seems to be in dismiss
actions being handled too late. One easy-to-duplicate case is the
tile-picker. When it's enabled and you commit a turn I post first the
confirmation and then, in response to a "yes", the picker. But the
picker gets added to the stack moments before the confirmation is
removed, and it's the nature of stack removal that everything above
what's being removed gets pulled too. So you never see the
picker. Simply post()ing a runnable to put the picker up later fixes
this one case, but a similar trick doesn't work elsewhere, so I'm
punting until I have time to root-cause the problem.
2017-04-13 08:18:07 -07:00
Eric House
3bff16193a ignore more stuff 2017-04-13 08:05:56 -07:00
Eric House
5bbfd44333 try to dismiss duplicate alerts
Each alert gets a unique name. Add to backstack, and before doing so
look for another with the same name and dismiss it. This works most of
the time, especially to prevent them from piling up with orientation
changes. But in a robot-vs-robot game, and occasionally in a game with
three robots and one not, SCORE alerts stack up. It's the removal that's
failing, not the test for a duplicate, so perhaps I need to somehow wait
for it to succeed before adding the new alert.
2017-04-12 07:37:53 -07:00
Eric House
fdd1e5c148 fix NPE in new logging code 2017-04-10 20:33:25 -07:00
Eric House
cbac691be3 fix crash on old (2.3) devices
Was already using the safe test for wifidirect everywhere else...
2017-04-10 20:32:11 -07:00
Eric House
c774780730 don't display info about disabling when disabled 2017-04-10 06:56:09 -07:00
Eric House
6c5ab3ff1a tweak changelog order 2017-04-08 14:36:30 -07:00
Eric House
f33488f020 fix release builds
Gradle'd changed the name of one of the signing-related tasks.
2017-04-08 14:29:07 -07:00
Eric House
32c264cc16 cleanup: got confused by two separated hide tests 2017-04-08 14:09:34 -07:00
Eric House
0e90286d92 tweak tile-picker alert titles 2017-04-08 13:45:42 -07:00
Eric House
9e66d294a2 tap on pending blank tile brings up picker
It's been annoying to have to move a placed blank to change its
value. No more.
2017-04-08 13:44:59 -07:00
Eric House
832b3adfd2 cleanup; fail safely
Remove or fix some logging; in a case that rarely shows a NPE check
first but only assert on debug builds. Fail silently on release builds.
2017-04-08 13:15:24 -07:00
Eric House
4668beee78 reveal timer start field if timer's enabled
Rotation was hiding it once enabled.
2017-04-08 12:20:20 -07:00
Eric House
5b7559c223 debug-build-only logging of pane order
I'm seeing infrequent switching of panes' ordering when
rotating. Logging them hoping to see if it's in the layout or elsewhere.
2017-04-08 12:11:53 -07:00
Eric House
b07fd2699c remove incorrect assertion
DELETE_DICT Action is expected to flow through child, at least until I
fix to disable deleting a dict while it's open in the dict browser. It
may be confusing but with the assert gone does no harm.
2017-04-08 11:40:54 -07:00
Eric House
1f3d1cbb79 make force-tablet debug pref a three-way
Rather than force/don't, which doesn't let tablets force themselves to
be phones, allow choice between OS default and forcing either way.
2017-04-08 11:04:45 -07:00
Eric House
32140ff4e5 ignore generated files and build files 2017-04-08 11:04:23 -07:00
Eric House
7717272f68 Capitalize the W: Crosswords -> CrossWords
Too much confusion with crossword puzzle apps
2017-04-08 10:08:18 -07:00
Eric House
8ec48bfee8 fix typo 2017-04-08 09:26:09 -07:00
Eric House
ac932758b2 remove unused strings
fix script to search in new location and remove the strings it flags.
2017-04-07 00:58:59 -07:00
Eric House
d9944252f6 cleanup old dialog code
remove some old stuff from pre-dialogfragment dialog handling. What's
left still needs auditing, as I'm not sure whether it can get called.
2017-04-07 00:33:45 -07:00
Eric House
50fe363da9 move notice about new dual-pane feature
Make the default be that it's on, and move the new-feature notice from
app launch to board open, the point where most will see the feature for
the first time. Remove the notify-and-exit thing, which is harder to
make work from the board, instead just posting an alert, if user chooses
to disable, that the setting change takes effect after a restart.
2017-04-07 00:23:37 -07:00
Eric House
b40f938fcb fix dbg variant: remove duplicate from manifest 2017-04-06 21:11:55 -07:00
Eric House
55339b6aaf fix release compile warnings 2017-04-06 07:43:20 -07:00
Eric House
bbae0ab6ed up version strings
Easier to test dualpane upgrade notification with new version in place.

And remove version code from manifest, since it's duplicated in build.gradle.
2017-04-06 07:39:30 -07:00
Eric House
966c48bd57 fix build (forgot new file) 2017-03-28 21:45:03 -07:00
Eric House
c496cf5a1f include room name in games list when pending
I can't send a manual invitation without that information
2017-03-28 07:10:45 -07:00
Eric House
e7d4e93d12 Use Log.? instead of DbgUtils.log? everywhere
Too much trouble switching modes between work and home :-)
2017-03-28 06:54:42 -07:00
Eric House
059bf82392 redo invite/wait alert after invitation sent
Needs to show different text and buttons, so now that it isn't getting
dismissed and rebuilt every time a button's pressed force that process
manually the time it's required.
2017-03-27 07:20:32 -07:00
Eric House
a5d0d02faf pass Context fix NotSerializableException
Backgrounding with Wait/Invite alert up mean serializing something that
included a Context. Fix to pass it instead into methods that need it.
2017-03-27 07:16:13 -07:00
Eric House
e7a2657a91 override onResume not onStart to fix NPE
When game's resumed (brought from background) and Wait alert is up
onStart() is called before getDialog() has a non-null value to
return. onResume() is the place to modify the dialog.
2017-03-27 07:07:05 -07:00
Eric House
58e5145296 another try: make AlertDialog not exit from buttons
Rewrote Wait/Invite alert to use new functionality that allows it to set
its AlertDialog buttons to not exit when tapped. Turns out things are
much simpler when I don't have to hook into all the places my dialog
might need to be put up again.
2017-03-24 19:58:28 -07:00