2013-12-05 Miguel de Dios <miguel.dedios@artica.es>
* src/pandroid_event_viewer/pandorafms/Main.java: fixed to check the pandora version for 4 series, this is for to hidden the tag filter. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@9166 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
b26855992c
commit
db0028003c
|
@ -1,3 +1,8 @@
|
|||
2013-12-05 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* src/pandroid_event_viewer/pandorafms/Main.java: fixed to check the
|
||||
pandora version for 4 series, this is for to hidden the tag filter.
|
||||
|
||||
2013-12-05 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* src/pandroid_event_viewer/pandorafms/API.java: fixed the offset
|
||||
|
|
|
@ -54,6 +54,7 @@ import android.widget.ImageButton;
|
|||
import android.widget.LinearLayout;
|
||||
import android.widget.Spinner;
|
||||
import android.widget.SpinnerAdapter;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
|
||||
/**
|
||||
|
@ -94,12 +95,6 @@ public class Main extends Activity {
|
|||
this.getString(R.string.const_string_preferences),
|
||||
Activity.MODE_PRIVATE);
|
||||
|
||||
if (preferences.getString("api_version", "")
|
||||
.equals(VERSION_4_0_2_LABEL)) {
|
||||
|
||||
version402 = true;
|
||||
}
|
||||
|
||||
setContentView(R.layout.main);
|
||||
final Button buttonSetAsFilterWatcher = (Button) findViewById(R.id.button_set_as_filter_watcher);
|
||||
final ImageButton buttonSearch = (ImageButton) findViewById(R.id.refresh_icon_button_main);
|
||||
|
@ -278,14 +273,31 @@ public class Main extends Activity {
|
|||
public void onResume() {
|
||||
super.onResume();
|
||||
|
||||
final SharedPreferences preferences = getSharedPreferences(
|
||||
this.getString(R.string.const_string_preferences),
|
||||
Activity.MODE_PRIVATE);
|
||||
|
||||
Log.i(TAG, "Getting groups and tags");
|
||||
GetGroupsAsyncTask task_group = new GetGroupsAsyncTask();
|
||||
task_group.execute();
|
||||
|
||||
// Get the short form of the version. I.E. "v4" for "v4.01" and others
|
||||
// 4 versions
|
||||
String api_version = preferences.getString("api_version", "");
|
||||
String[] api_version_short = api_version.split("\\.");
|
||||
|
||||
if (api_version_short[0].equals("v4")) {
|
||||
version402 = true;
|
||||
}
|
||||
|
||||
if (version402) {
|
||||
((EditText) findViewById(R.id.tag_text))
|
||||
.setVisibility(View.VISIBLE);
|
||||
.setVisibility(View.GONE);
|
||||
((Spinner) findViewById(R.id.tag)).setVisibility(View.GONE);
|
||||
|
||||
((TextView) findViewById(R.id.tag_textview))
|
||||
.setVisibility(View.GONE);
|
||||
|
||||
}
|
||||
else {
|
||||
new GetTagsAsyncTask().execute();
|
||||
|
|
Loading…
Reference in New Issue