Commit graph

9585 commits

Author SHA1 Message Date
Eric House
d26a215f34 add and use fragment for dicts list view 2016-07-18 13:08:06 -07:00
Eric House
1ed9dc7c9d fix onResult stuff, at least for game config 2016-07-18 12:54:52 -07:00
Eric House
5bb707fc57 fix unnecessary crashes launching prefs activity 2016-07-18 12:03:56 -07:00
Eric House
d0b64f8f51 Merge branch 'android_108_release' into android_branch 2016-07-18 10:17:44 -07:00
Eric House
4f067edece up version code (since already uploaded as a beta) 2016-07-18 09:31:41 -07:00
Eric House
01ffdb8b87 up changes log to include new fix 2016-07-18 09:27:33 -07:00
Eric House
959b2aec33 don't dismiss alert when about to post it again
On 4.2 and 4.3 at least, the dimiss comes after the second post
causing that to be dismissed, leaving no alert and the app in some
weird state where not even the back button works. It's been this way
on those older versions since I redid invitations for beta 98.
2016-07-18 09:23:14 -07:00
Eric House
5f8e5dc343 don't dismiss alert when about to post it again
On 4.2 and 4.3 at least, the dimiss comes after the second post
causing that to be dismissed, leaving no alert and the app in some
weird state where not even the back button works. It's been this way
on those older versions since I redid invitations for beta 98.
2016-07-18 09:19:09 -07:00
Eric House
b5afc25ead catch up with generated changes: there's a new localized language now 2016-07-18 08:49:57 -07:00
Eric House
e3c5028b83 make script actually work 2016-07-18 08:49:36 -07:00
Eric House
f91e5f68c7 don't save state we won't need 2016-07-18 08:49:15 -07:00
Eric House
5a0304904f sdk's generating an additional comment for German strings 2016-07-14 07:37:59 -07:00
Eric House
db0fb8e2f1 cleanup: remove EOL whitespace from java files
New diff tool is complaining about it, and sed is so easy...
2016-07-14 07:37:11 -07:00
Eric House
15256ac2ad cleanup 2016-07-14 07:01:02 -07:00
Eric House
dcb4968ed9 fix NPE
I think I'm in a bad state when this happens, but no point in
crashing regardless.
2016-07-13 17:08:39 -07:00
Eric House
472a173297 disable delete if selected game is currently open 2016-07-13 17:03:18 -07:00
Eric House
1be2d514f0 Don't call executePendingTransactions().
Not doing so no longer crashes on when handling notifications, and is
causing runtime exceptions from the OS when board opening chat causes
it to be called recursively.
2016-07-13 16:42:58 -07:00
Eric House
7b2392842e handle orientation changes at least as well as the old dualpane stuff
did. Only obvious problem is that the board doesn't always lay itself
out optimally for its half of the board when orientation changes.
2016-07-13 15:50:48 -07:00
Eric House
325304d83d fix finish() to not exit whole activity in dualpane mode 2016-07-13 13:35:31 -07:00
Eric House
a7013f3ede Setting FLAG_ACTIVITY_SINGLE_TOP for notification intents fixes
display problems with GamesList in dual-pane mode, I think because it
prevents stacked activities. Need to figure out if it introduces
problems elsewhere.
2016-07-13 12:35:54 -07:00
Eric House
9cfed0be8b add, disabled, some logging/notification posting stuff useful for debugging 2016-07-13 12:29:42 -07:00
Eric House
54e5e61e4d dispatch backPressed to the right-most fragment before, if still
unhandled, letting super interpret it as a pop-fragment action.
2016-07-13 12:23:36 -07:00
Eric House
4fc2dd97b3 handle notification intents: each delegate gets a chance to handle
them (only GamesListDelegate does), and MainActivity pops
fragments/delegates until one's exposed that does.
2016-07-13 11:13:04 -07:00
Eric House
0c4c1af926 call executePendingTransactions() to fix crash on opening
notification. Not sure why I had it commented out before.
2016-07-13 09:14:30 -07:00
Eric House
a375aed0fa use class.getSimpleName() rather than getName for logging 2016-07-13 09:07:48 -07:00
Eric House
dd96c1a5c2 cleanup: change map key type 2016-07-11 12:31:42 -07:00
Eric House
91c561f6aa fix NPEs by using existing mechanism for finding the right DlgDelegate
instance.
2016-07-11 11:52:55 -07:00
Eric House
a2b7c71fc1 convert remaining delegate launches to work, to varying degrees (but
as they did before), in dual pane mode.
2016-07-10 15:01:19 -07:00
Eric House
76404258a3 launch chat next to board. Works to send, but crash when opening the
notification that results.
2016-07-10 14:21:18 -07:00
Eric House
b8b73cc321 change how games are launched: works to show next to games list! But
there seems to be something wrong with how alerts are being posted.
2016-07-10 14:16:01 -07:00
Eric House
9865c0c68c load new dualpane delegate when enabled. It does nothing so far, not
even allowing you to disable it again.
2016-07-10 13:26:09 -07:00
Eric House
377ac269c9 Turn enable-dualpane prefs back on. Ignored so far. 2016-07-10 13:12:29 -07:00
Eric House
12b1f3e38b rename GamesListActivity -> MainActivity 2016-07-10 13:09:20 -07:00
Eric House
c3817ef452 change version strings for new release 2016-07-08 06:18:07 -07:00
Eric House
c11c1f4a64 save and restore chat text selection 2016-07-07 06:37:33 -07:00
Eric House
91a58ab041 position caret at end of restored chat pending text 2016-07-06 21:39:55 -07:00
Eric House
a86ff8b7b0 revert change that broke board updating on 2.3.7. Yay for git
bisect!!!!
2016-07-05 20:17:55 -07:00
Eric House
9dc50c9aa8 preserve unsent chats across activity reload. Use pairs table rather
than creating a new one.
2016-07-03 12:32:32 -07:00
Eric House
f05375273c add send button to right of chat entry field for devices that don't
have action bar.
2016-07-02 12:54:04 -07:00
Eric House
68df61daa8 fix crash on old device by using new API conditionally 2016-07-02 12:29:16 -07:00
Eric House
88d8e61620 cleanup; tweak string 2016-07-02 12:28:57 -07:00
Eric House
1a6f5842c6 wait for dismissal of one alert before posting another. There really
needs to be some sort of queuing built into DlgDelegate, but for now
just handle in this one place.
2016-06-30 08:01:58 -07:00
Eric House
446663ea86 update to new gradle plugin as recommended/generated by AS 2016-06-30 07:15:21 -07:00
Eric House
624ec870f2 clean up .gitignore files for localization stuff 2016-06-30 07:01:30 -07:00
Eric House
2f71119eea add ability to skip including localization resources on per-language,
per-variant basis. Just in case German isn't ready yet.
2016-06-30 06:54:36 -07:00
Eric House
a243b19fd0 fix NPE when relay's re-added to a game 2016-06-30 06:21:12 -07:00
Eric House
03492b97e8 fix doubled response to alert button: dismiss != negative 2016-06-29 07:01:08 -07:00
Eric House
f66fa5f75a cleanup: remove commented out code etc. 2016-06-28 06:05:31 -07:00
Eric House
3bc60c59d0 Add option to remove relay from a game once it's been turned off. 2016-06-26 15:53:26 -07:00
Eric House
3d682c425f remove Main activity 2016-06-26 15:41:15 -07:00
Eric House
94dadd4ca3 fix for single-device case 2016-06-26 14:54:01 -07:00
Eric House
3651137016 Merge branch 'android_branch' of ssh://maidu2/home/eehouse/src/git/repos/xwords into android_branch
# Please enter a commit message to explain why this merge is necessary,
# especially if it merges an updated upstream into a topic branch.
#
# Lines starting with '#' will be ignored, and an empty message aborts
# the commit.
2016-06-26 14:38:50 -07:00
Eric House
e703ae7ec5 get rid of Main activity. Next release I need to find a way at launch
time to choose between dual-pane and regular mode that doesn't mess
up sending Intents and make it harder to prevent there being
multiple instances of activities that are supposed to be single-top.
2016-06-26 14:28:17 -07:00
Eric House
6c5b5489ad cleanup: Remove some commented-out code 2016-06-26 13:53:59 -07:00
Eric House
61ea4b01e1 ignore files 2016-06-24 22:40:35 -07:00
Eric House
89a0426521 Merge remote-tracking branch 'weblate/android_translate' into android_translate 2016-06-24 22:37:24 -07:00
Eric House
372b0c2f1e when user tries to turn on the preference disabling relay play and has
relay games in play, warn, and only disable if confirmed.
2016-06-24 21:19:30 -07:00
Eric House
aab779f258 duh: we're storing whether it's disabled, so reverse boolean 2016-06-23 06:27:01 -07:00
Eric House
7d47098947 start/stop relay service when pref changed; warn user when opens
relay-connected game and relay is disabled.
2016-06-22 07:20:23 -07:00
Eric House
6ef9c60cb9 add some generated .gitignore files 2016-06-22 06:53:02 -07:00
Eric House
aef5e5e046 add preference, off by default, to disable relay play. This is for
people who use the app for standalone play only and don't like the
battery implications of it hitting the network (which it does too
often right now.)
2016-06-21 06:08:25 -07:00
Eric House
a4ab8658fb something's adding line in a different format to .gitignore files; go
with it.
2016-06-20 07:25:32 -07:00
Eric House
bd08b0cfee cleanup: remove unneeded imports (from one old file) 2016-06-17 07:14:45 -07:00
Eric House
dc92007811 add grep: start process of having this script add value 2016-06-14 06:05:05 -07:00
Eric House
bba16c481e improve game query script to filter on connnames and clarify filter param 2016-06-12 18:30:19 -07:00
Eric House
03efa3a7e6 toward being able to do release builds of CrossDbg 2016-06-09 21:30:04 -07:00
Eric House
777b1a7aab turn off dualpane option. It's broken: makes it too easy to get lots
of instances of the games list and board views stacked on top of each
other.
2016-06-08 21:36:33 -07:00
Eric House
44c4d50051 Add config.xml file and use to enable dualpane option for CrossDbg builds 2016-06-07 04:31:31 -07:00
Eric House
032d073d6f cleanup: there's no solo network status any more 2016-05-31 06:28:48 -07:00
Roland Illig
16cbbc5bee Translated using Weblate (German)
Currently translated at 8.4% (62 of 730 strings)
2016-05-31 03:44:40 +02:00
Eric House
d3318f6631 fix chat edittext to expand vertically when there's more than one line
of text in it.
2016-05-30 15:14:52 -07:00
Eric House
124c85a2e9 fix gradle builds too to use combined constants files 2016-05-30 13:13:01 -07:00
Eric House
49e7abd23d Combine the two generated constants files 2016-05-30 13:10:20 -07:00
Bernard Massot
6e16ec69c1 Translated using Weblate (French)
Currently translated at 100.0% (730 of 730 strings)
2016-05-29 18:46:59 +02:00
Roland Illig
75f14a985a Added translation using Weblate (German) 2016-05-29 02:34:06 +02:00
naofum
48ddd271dc Translated using Weblate (Japanese)
Currently translated at 100.0% (730 of 730 strings)
2016-05-28 13:01:01 +02:00
Weblate
b14c6b5003 Merge remote-tracking branch 'origin/android_translate' into android_translate 2016-05-28 08:43:40 +02:00
Eric House
06ef079af1 fix. seems to do gradle builds correctly, though those builds need a
lot of work still.
2016-05-23 08:39:51 -07:00
Eric House
8082a1e0dc add files generated as a result of earlier change 2016-05-23 08:39:05 -07:00
Eric House
28a7d425cd remove gradle build files from a directory where, AFAIK,they don't belong 2016-05-23 08:37:50 -07:00
Eric House
73598462b8 don't include carriage return in generated file name 2016-05-23 07:42:43 -07:00
Eric House
f8cfb9cc44 change string and enum name to indicate Bluetooth is where the connect
failure is.
2016-05-21 14:35:53 -07:00
Eric House
f001455589 fix so tablets are found in BT scans: they're considered computers, not phones 2016-05-21 14:25:54 -07:00
Eric House
f51565839a no need to set summary to null when pausing. 2016-05-21 14:05:47 -07:00
Eric House
e127c8a3aa fix to uninstall (by default) based on directory invoked from 2016-05-21 13:36:56 -07:00
Eric House
17945b2dc0 turn on auto-capitalization of sentences in chat 2016-05-17 22:21:11 -07:00
Eric House
4791ccaca8 commented out code to add notification used to duplicate the bug
addresses by the previous commit.
2016-05-17 21:09:32 -07:00
Eric House
80ebcff4c9 Handle case where we want to open a game that's already open (likely
in the process of being closed.) If we're successful in getting a
JNIThread object that's already initialized, re-use it, closing only
the JNI part (which probably can't be cleanly re-used with a different
Context.) I worry about the case where the thread's event queue isn't
empty, so there's an assert to catch that case.
2016-05-17 21:08:03 -07:00
Eric House
79efbd2076 upgrade gradle (recommended by AS) 2016-05-17 20:56:31 -07:00
Eric House
253c0d7496 turn off saving logs for now; move capture of title to where it's more
likely to succeed, and assert that it is. I think this will fix the
title-not-reverting problem I've been seeing.
2016-05-10 06:40:23 -07:00
Eric House
608533d189 Merge branch 'from_android_beta_106' into android_branch 2016-05-03 06:44:39 -07:00
Eric House
c013c152d7 up version strings for release 107 (f-droid only is the plan) 2016-05-02 21:56:11 -07:00
Eric House
f0dc295bde break gradle release builds with an error message that will, with
luck, communicate to the f-droid maintainer that ant it still the way
to build. Should stop the flood of error reports from f-droid users.
2016-05-02 21:45:53 -07:00
Eric House
1cb75bd970 turn off an especially oft-occurring log message 2016-04-22 21:14:58 -07:00
Eric House
d376679d00 add new database table for persisting logs. DEBUG builds only for
now. Keep the most recent 5K worth of messages. TODO: add a display
activity and the ability to email them.
2016-04-22 21:14:36 -07:00
Eric House
1216ec49d7 cleanup: move method 2016-04-22 07:08:13 -07:00
Eric House
bf871a20fb test for null to avoid NPE. I'm not sure how it gets here -- race
condition on opening maybe -- but not showing the one menuitem in this
case is harmless.
2016-04-21 06:35:42 -07:00
Eric House
18503f2237 If we get an intent and can't open the game it names, that's probably because GamesListActivity has been relauched on top of itself. So exit with a (temporary) Toast message. 2016-04-20 21:50:09 -07:00
Eric House
c9a1f00a43 catch up with non-dbg changes, esp. enabling dual-pane mode (though
it's off now thanks to a compile-time constant)
2016-04-18 06:21:49 -07:00
Eric House
406eb77f54 post notification (rather than just play sound) when turn comes into
boarddelegate but it's not visible
2016-04-14 22:16:18 -07:00
Eric House
c860773234 still learning magit: check preference before playing sound 2016-04-14 21:50:18 -07:00
Eric House
99effcac89 looks like I missed a hunk in previous commit 2016-04-14 21:42:22 -07:00
Eric House
e239430260 play notification sound when a move or chat is added to the board or
chat view. Still TODO: post a notification when that view isn't visible.
2016-04-14 21:39:23 -07:00
Eric House
994672667c gitignore some stuff 2016-04-14 21:07:12 -07:00
Eric House
33225f3bc5 refactor message receiving/distributing code into superclass. 2016-04-11 06:01:25 -07:00
Eric House
f288fe2860 use malloc to allocate storate for hci_inquiry instead of the
stack. That *seems* to fix it always returning 0, something that
changed with newer version of linux or libbluetooth or who knows
what. BT still doesn't work from linux, but this is a necessary start.
2016-04-09 15:49:11 -07:00
Eric House
a0ae117e35 fix invitations breakage introduced when JNIThread because self-initing. 2016-04-09 14:47:48 -07:00
Eric House
27b3004b43 exclude computers from BT paried devices scan -- since doesn't work on
ubuntu right now.
2016-04-09 13:57:16 -07:00
Eric House
baee084a90 add assert to catch case where exception may otherwise be thrown 2016-04-09 13:34:13 -07:00
Eric House
57dcbabab6 use a constant 2016-04-09 13:10:04 -07:00
Eric House
04a697b260 fix NPE: put back setReceiver() call lost when JNIThread became
self-initing.
2016-04-09 12:42:47 -07:00
Eric House
3dd69d90d9 This stuff has to be done before content gets added. Move into
Activity for now, though this may not work in dual-pane mode.
2016-04-09 12:23:26 -07:00
Eric House
8c9e3ce14c use pthreads mutex to synchronize alloc and free operations in (debug
only) mpool. I'm getting assertions about failure to free now that
multiple threads are accessing open games, but I think they're bogus:
due to multiple threads modifying the leak-detection counters. This
seems to fix the assertions I was seeing in mpool_destroy().
2016-04-09 11:54:08 -07:00
Eric House
f876c49cd6 don't require that ant be run before install 2016-04-09 11:51:48 -07:00
Eric House
1c6e97e164 AS-generated changes adapting to the 2.0 release 2016-04-07 12:34:58 -07:00
Eric House
589535cdbc Make JNIThread responsible for opening/owning game and other objects
whose lifespan matches its, e.g. the gameptr and gi. This is a big
change, and there are still some bugs/crashes, but it's worth
committing this snapshot.
2016-04-07 12:23:13 -07:00
Eric House
160d69640a log refcount changes 2016-04-07 09:48:23 -07:00
Eric House
b2c4bd9e23 better chat text hint 2016-04-07 09:30:29 -07:00
Eric House
14bdde7ff0 save game whenever refcount is released. Works around BoardDelegate
reloading the game every time it resumes. Better fix would be to have
JNIThread() own loading the game and only do so when first created.
2016-04-07 09:27:00 -07:00
Eric House
d541c976bf add PENDING comment 2016-04-07 09:23:07 -07:00
Eric House
9f05d45e05 sometimes when return from background ChatDelegate is the first to try
to reference JNIThread. Until I can make that work, just finish() --
to avoid crashes.
2016-04-07 09:22:41 -07:00
Eric House
049c25f16d save when exiting to prevent data loss opening chat window. 2016-04-06 21:41:48 -07:00
Eric House
a55e17cd41 cleanup; log rowid in release() and retain() 2016-04-06 21:40:46 -07:00
Eric House
a90ec29ff0 fix delete game problem: delete first using lock we already have. 2016-04-06 18:42:37 -07:00
Eric House
3a368a8efd toward working better in background: log and print stack when doing
nothing because jnithread is null. Pass incoming chat messages to
ChatDelegate if it's up, and otherwise launch it as before.
2016-04-06 11:16:51 -07:00
Eric House
919e44f21e first cut at accepting input when running. Won't work when whole app is in background. 2016-04-06 11:08:27 -07:00
Eric House
347ff60434 toward working in background: log when called on null thread rather than crashing 2016-04-06 11:07:30 -07:00
Eric House
70c0db6504 chat: add hint string, and make textfield full width 2016-04-06 11:06:10 -07:00
Eric House
4bb16e88ef better logging 2016-04-06 11:03:18 -07:00
Eric House
7b045fb413 add constant to disable dualpane on debug builds too 2016-04-06 11:03:02 -07:00
Eric House
f6cbe2ec61 Toward launching fragment for result. Fires an assert on returning
since that's not done yet.
2016-04-05 09:37:17 -07:00
Eric House
b68775b620 oops -- fix compilation error 2016-04-05 09:17:03 -07:00
Eric House
b3f6e1b0a3 Make config work as a fragment, and clean up all the fragment
subclasses: only one method needs to be overridden.
2016-04-05 08:56:33 -07:00
Eric House
8cb2cecc18 add logging toward catching board layout problems; throw exception
when can't unlock game (possible fix to multiple instances of
GamesListActivity stacking up); cleanup of GamesListDelegate tracking
of open games.
2016-04-05 08:18:12 -07:00
Eric House
21ef6d4e13 tossing stuff at the wall trying to fix occasional failures to layout
board in dual-pane mode (that show up as all-white BoardView). I think
there was a slight reduction in frequency, which varies with screen
size at least.
2016-04-04 14:30:04 -07:00
Eric House
ae8a66f37b snapshot on the way to handling rotation of the board view. Pass
orientation changes down to it (or any other interested delegate), and
have it lay its container out again. There appear to be race
conditions here: sometimes the toolbar winds up in the wrong
orientation, and on some devices the board can be blank. One problem
is that on a multi-paned device a single pane may be portrait (taller
than wide) though the whole device is in landscape mode. The big
challege is to get the view's max dimensions (and whether it's
landscape or portrait) when layout hasn't yet begun, because we that
for the jni part of layout. Messy still, but better than before and I
think progress in the right direction.
2016-04-04 13:43:16 -07:00
Eric House
b6431f0373 when normal means don't succeed in generating summary, try again with
via JNIThread's cache.
2016-04-04 11:35:39 -07:00
Eric House
f47a11aa42 snapshot of changes adding refcounting to jnithread so and instance
can be shared by multiple delegates, e.g. Board and Chat. Works but
with lots of crashes and stuff remaining to be done.
2016-03-31 22:05:58 -07:00
Bernard Massot
1aba000f89 Translated using Weblate (French)
Currently translated at 99.4% (721 of 725 strings)
2016-03-31 00:44:28 +02:00
Bernard Massot
e8cf76be72 Translated using Weblate (French)
Currently translated at 99.4% (721 of 725 strings)

this string should be split into a singular and a plural versions
2016-03-28 21:46:12 +02:00
Bernard Massot
978f15d1c9 Translated using Weblate (French)
Currently translated at 99.4% (721 of 725 strings)
2016-03-28 21:45:59 +02:00
Bernard Massot
4ca62547fc Translated using Weblate (French)
Currently translated at 99.4% (721 of 725 strings)

this string should be split into a singular and a plural versions
2016-03-28 21:00:24 +02:00
Bernard Massot
fb66c6ecbc Translated using Weblate (French)
Currently translated at 97.2% (705 of 725 strings)
2016-03-28 20:38:41 +02:00
Eric House
b6f992533a fix NPE. Method isn't called unless positive/confirming button has
been pressed.
2016-03-19 05:44:37 -07:00
Eric House
ab26e263ef cleanup: remove unnecessary file. 2016-03-14 22:01:55 -07:00
Eric House
0bc6387714 add support for behavior: when the left fragment opens a new fragment
it replaces the right one rather than pushing the left off the
screen. Use that to make dictionary browser, chat, and studylist all
able to swap places while the open board is on the left.
2016-03-14 21:48:07 -07:00
Eric House
f23a28cbce log onDestroy too 2016-03-14 21:46:28 -07:00
Eric House
0a843bd430 add chat fragment, which displays ok but can't send. Turn menus off/on
as fragments are made visible.
2016-03-13 19:53:59 -07:00
Eric House
c35020ef97 Merge branch 'android_branch' into android_dualpane2
Conflicts:
	xwords4/android/XWords4/archive/R.java
2016-03-13 17:27:02 -07:00
Eric House
61ff6a6c33 Merge branch 'android_beta_106_branch' into android_branch
Conflicts:
	xwords4/android/XWords4/src/org/eehouse/android/xw4/ChatDelegate.java
2016-03-13 17:16:47 -07:00