From fbe978e343cb39c21e30beb264155725d736407e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lars=20Jans=F8n=20Engvik?= Date: Mon, 5 Dec 2011 15:37:46 +0100 Subject: [PATCH 1/2] Changed name. --- res/values/strings.xml | 2 +- src/com/studentersamfundet/app/ui/BaseDnsActivity.java | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/res/values/strings.xml b/res/values/strings.xml index 20882c0..c71f724 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -1,6 +1,6 @@ - Det Norske Studentersamfund + Studentersamfundet PROGRAM BLI MED Gå til nettsiden diff --git a/src/com/studentersamfundet/app/ui/BaseDnsActivity.java b/src/com/studentersamfundet/app/ui/BaseDnsActivity.java index 6068f85..495e4ae 100644 --- a/src/com/studentersamfundet/app/ui/BaseDnsActivity.java +++ b/src/com/studentersamfundet/app/ui/BaseDnsActivity.java @@ -4,6 +4,7 @@ import com.studentersamfundet.app.R; import android.app.Activity; import android.content.Intent; +import android.net.Uri; import android.os.Handler; import android.view.View; @@ -23,11 +24,13 @@ public abstract class BaseDnsActivity extends Activity { /* Join button was pushed: */ } else if (v.getId() == R.id.bli_med_button) { - intent.setFlags(Intent.FLAG_ACTIVITY_NO_HISTORY + /*intent.setFlags(Intent.FLAG_ACTIVITY_NO_HISTORY | Intent.FLAG_ACTIVITY_SINGLE_TOP); intent.setClass(this, JoinUsActivity.class); - startActivity(intent); + startActivity(intent);*/ + Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("http://studentersamfundet.no/bliaktiv.php")); + startActivity(browserIntent); /* The header was pushed: */ } else if (v.getId() == R.id.header) { From 71c3da79b405ef90dca71fd839c13641b42c504d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lars=20Jans=F8n=20Engvik?= Date: Mon, 5 Dec 2011 16:29:32 +0100 Subject: [PATCH 2/2] Fixed opening hours and added Glassbaren. --- project.properties | 11 ------- .../app/ui/BaseDnsActivity.java | 7 ++--- .../app/ui/DnsActivity.java | 29 +++++++++++++------ 3 files changed, 22 insertions(+), 25 deletions(-) delete mode 100644 project.properties diff --git a/project.properties b/project.properties deleted file mode 100644 index ea89160..0000000 --- a/project.properties +++ /dev/null @@ -1,11 +0,0 @@ -# This file is automatically generated by Android Tools. -# Do not modify this file -- YOUR CHANGES WILL BE ERASED! -# -# This file must be checked in Version Control Systems. -# -# To customize properties used by the Ant build system use, -# "ant.properties", and override values to adapt the script to your -# project structure. - -# Project target. -target=android-8 diff --git a/src/com/studentersamfundet/app/ui/BaseDnsActivity.java b/src/com/studentersamfundet/app/ui/BaseDnsActivity.java index 98c9fbd..8b4600d 100644 --- a/src/com/studentersamfundet/app/ui/BaseDnsActivity.java +++ b/src/com/studentersamfundet/app/ui/BaseDnsActivity.java @@ -4,7 +4,6 @@ import com.studentersamfundet.app.R; import android.app.Activity; import android.content.Intent; -import android.net.Uri; import android.os.Handler; import android.view.View; @@ -24,13 +23,11 @@ public abstract class BaseDnsActivity extends Activity { /* Join button was pushed: */ } else if (v.getId() == R.id.bli_med_button) { - /*intent.setFlags(Intent.FLAG_ACTIVITY_NO_HISTORY + intent.setFlags(Intent.FLAG_ACTIVITY_NO_HISTORY | Intent.FLAG_ACTIVITY_SINGLE_TOP); intent.setClass(this, JoinUsActivity.class); - startActivity(intent);*/ - Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("http://studentersamfundet.no/bliaktiv.php")); - startActivity(browserIntent); + startActivity(intent); /* The header was pushed: */ } else if (v.getId() == R.id.header) { diff --git a/src/com/studentersamfundet/app/ui/DnsActivity.java b/src/com/studentersamfundet/app/ui/DnsActivity.java index 925f27b..a4e6f48 100644 --- a/src/com/studentersamfundet/app/ui/DnsActivity.java +++ b/src/com/studentersamfundet/app/ui/DnsActivity.java @@ -17,22 +17,31 @@ import com.studentersamfundet.app.R; public class DnsActivity extends BaseDnsActivity { String[] openingHoursHouse = { - "13.00 - 01.00", - "13.00 - 01.00", - " - 01.30", - " - 03.00", - " - 03.00", - "15.00 - 03.00", - " - 19.00"}; + "10.00 - 01.00", + "10.00 - 01.00", + "10.00 - 01.00", + "10.00 - 03.00", + "10.00 - 03.00", + "12.00 - 03.00", + "12.00 - 20.00"}; + + String[] openingHoursGB = { + "13.00 - 01.00", + "13.00 - 01.00", + "13.00 - 01.00", + "13.00 - 03.00", + "13.00 - 03.00", + "16.00 - 03.00", + "Stengt"}; String[] openingHoursBC = { - "Stengt", "19.00 - 00.00", "19.00 - 00.00", "19.00 - 00.00", "19.00 - 03.00", "19.00 - 03.00", - "20.00 - 03.00"}; + "20.00 - 03.00", + "Stengt"}; /** Called when the activity is first created. */ @Override @@ -43,10 +52,12 @@ public class DnsActivity extends BaseDnsActivity { /* Set opening hours: */ TextView tvNeuf = (TextView)findViewById(R.id.main_menu_hours_neuf); TextView tvBC = (TextView)findViewById(R.id.main_menu_hours_bc); + // TextView tvGB = (TextView)findViewById(R.id.main_menu_hours_gb); int day = (Calendar.getInstance().get(Calendar.DAY_OF_WEEK) + 5) % 7; tvNeuf.setText(openingHoursHouse[day]); tvBC.setText(openingHoursBC[day]); + // tvGB.setText(openingHoursBC[day]); setupFocus(); }