Skip to content

Commit

Permalink
Fixes GoodCitizen such that it continues rotating
Browse files Browse the repository at this point in the history
...after returning from a thumbnailed state into
fullscreen state and properly exits when closed.
  • Loading branch information
Anthony Hu committed Jul 26, 2012
1 parent 2c9f006 commit 6c947d2
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions GoodCitizen/main.c
Expand Up @@ -192,8 +192,6 @@ static void handleScreenEvent(bps_event_t *event) {
}

static void handleNavigatorEvent(bps_event_t *event) {
bps_event_t *activation_event = NULL;

switch (bps_event_get_code(event)) {
case NAVIGATOR_ORIENTATION_CHECK:
//Signal navigator that we intend to resize
Expand All @@ -219,9 +217,14 @@ static void handleNavigatorEvent(bps_event_t *event) {
break;
}

if (bps_event_get_code(activation_event)
== NAVIGATOR_WINDOW_ACTIVE) {
break;
if (event && (bps_event_get_domain(event) == navigator_get_domain())) {
int code = bps_event_get_code(event);
if (code == NAVIGATOR_EXIT) {
shutdown = true;
break;
} else if (code == NAVIGATOR_WINDOW_ACTIVE) {
break;
}
}
}
break;
Expand Down

0 comments on commit 6c947d2

Please sign in to comment.