Skip to content
Permalink
Browse files

use load indicator for interactive commands

  • Loading branch information...
ge0rg committed Apr 16, 2011
1 parent ba66837 commit 8b6e888339bd5e2fd14754dc6ecd9be22e492f6c
Showing with 6 additions and 0 deletions.
  1. +6 −0 src/UIHelper.scala
@@ -15,6 +15,10 @@ class UIHelper(ctx : Activity, menu_id : Int, prefs : PrefsWrapper)

var openedPrefs = false

def onStartLoading() {
ctx.asInstanceOf[LoadingIndicator].onStartLoading()
}

def trackOnMap(call : String) {
val text = ctx.getString(R.string.map_track_call, call)
Toast.makeText(ctx, text, Toast.LENGTH_SHORT).show()
@@ -131,6 +135,7 @@ class UIHelper(ctx : Activity, menu_id : Int, prefs : PrefsWrapper)
val min = ctx.getResources().getStringArray(R.array.age_minutes)(which)
prefs.prefs.edit().putString("show_age", min).commit()
ctx.sendBroadcast(new Intent(AprsService.UPDATE))
onStartLoading()
d.dismiss()
}})
//.setPositiveButton(android.R.string.ok, null)
@@ -158,6 +163,7 @@ class UIHelper(ctx : Activity, menu_id : Int, prefs : PrefsWrapper)
ctx.startActivity(new Intent(ctx, classOf[PrefsAct]));
true
case R.id.clear =>
onStartLoading()
new StorageCleaner(StorageDatabase.open(ctx)).execute()
true
case R.id.about =>

0 comments on commit 8b6e888

Please sign in to comment.
You can’t perform that action at this time.