From 58b85e4c246f154a867c5f52915f9a17c11065af Mon Sep 17 00:00:00 2001 From: Philipp Schaefer Date: Tue, 10 Dec 2013 22:14:24 +0100 Subject: [PATCH] new actionbar title for permalink --- code/utils_misc.js | 4 ++-- mobile/src/com/cradle/iitc_mobile/share/ShareActivity.java | 4 +--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/code/utils_misc.js b/code/utils_misc.js index 75d213e8..ef30baba 100644 --- a/code/utils_misc.js +++ b/code/utils_misc.js @@ -267,11 +267,11 @@ window.androidCopy = function(text) { } window.androidPermalink = function() { - if(typeof android === 'undefined' || !android || !android.copy) + if(typeof android === 'undefined' || !android || !android.intentPosLink) return true; // i.e. execute other actions var center = map.getCenter(); - android.intentPosLink(center.lat, center.lng, map.getZoom(), "Intel Map", false); + android.intentPosLink(center.lat, center.lng, map.getZoom(), "Selected map view", false); return false; } diff --git a/mobile/src/com/cradle/iitc_mobile/share/ShareActivity.java b/mobile/src/com/cradle/iitc_mobile/share/ShareActivity.java index b09e57f9..fe10d5c3 100644 --- a/mobile/src/com/cradle/iitc_mobile/share/ShareActivity.java +++ b/mobile/src/com/cradle/iitc_mobile/share/ShareActivity.java @@ -116,15 +116,13 @@ public class ShareActivity extends FragmentActivity implements ActionBar.TabList mZoom = intent.getIntExtra("zoom", 0); mIsPortal = intent.getBooleanExtra("isPortal", false); + actionBar.setTitle(mTitle); setupIntents(); } else { mTitle = getString(R.string.app_name); setupShareIntent(intent.getStringExtra("shareString")); } - // show portal name as action bar title, if available - if (mTitle != getString(R.string.app_name)) actionBar.setTitle(mTitle); - mViewPager = (ViewPager) findViewById(R.id.pager); mViewPager.setAdapter(mFragmentAdapter);