Merge upstream/master

pull/14/head
Sam Bosley 13 years ago
commit dd11d36160

@ -16,7 +16,6 @@
<classpathentry exported="true" kind="lib" path="libs/framework.jar"/>
<classpathentry exported="true" kind="lib" path="libs/httpmime-4.1.1.jar"/>
<classpathentry exported="true" kind="lib" path="libs/rfc2445-4Mar2011.jar"/>
<classpathentry exported="true" kind="lib" path="libs/guava-r09.jar"/>
<classpathentry exported="true" kind="lib" path="libs/jackson-core-asl-1.6.7.jar"/>
<classpathentry exported="true" kind="lib" path="libs/google-api-client-1.5.0-beta.jar"/>
<classpathentry exported="true" kind="lib" path="libs/google-api-client-extensions-1.5.0-beta.jar"/>
@ -28,7 +27,9 @@
<classpathentry exported="true" kind="lib" path="libs/google-oauth-client-extensions-1.5.0-beta.jar"/>
<classpathentry exported="true" kind="lib" path="libs/gson-1.6.jar"/>
<classpathentry exported="true" kind="lib" path="libs/google-api-services-tasks-v1-1.2.5-beta.jar"/>
<classpathentry kind="lib" path="libs/jchronic-0.2.3.jar"/>
<classpathentry kind="lib" path="libs/crittercism_v1_2_5.jar"/>
<classpathentry kind="lib" path="libs/jchronic-0.2.3.jar"/>
<classpathentry kind="lib" path="libs/android-support-v4.jar"/>
<classpathentry kind="lib" path="libs/guava-11.0.1.jar"/>
<classpathentry kind="output" path="bin/classes"/>
</classpath>

@ -54,6 +54,11 @@
<!-- extension targets. Uncomment the ones where you want to do custom work
in between standard targets -->
<target name="-set-mode-check" depends="clean">
<fail if="build.is.mode.set"
message="Cannot run two different modes at the same time. If you are running more than one debug/release/instrument type targets, call them from different Ant calls." />
</target>
<target name="-pre-build" depends="get-version, copy-sources, updatekeys, updatekeys-release, disable-market">
<mkdir dir="gen" />
</target>
@ -142,10 +147,10 @@
replace="\1 true;" />
</target>
<target name="obfuscate" depends="-setup">
<property name="proguard.enabled" value="true" />
<antcall target="-obfuscate" />
</target>
<target name="obfuscate" depends="-set-debug-files, -set-debug-mode, nodeps, -build-setup,
-set-release-mode, -release-obfuscation-check, -obfuscate" />
<target name="dex" depends="obfuscate, -dex" />
<!-- build custom release package with updated version name -->
<target name="release-custom">

@ -82,21 +82,12 @@ public class AstridChronic {
throw new RuntimeException("Failed to scan tokens.", e);
}
List<Class> scannerClasses = new LinkedList<Class>();
scannerClasses.add(Grabber.class);
scannerClasses.add(Pointer.class);
scannerClasses.add(Scalar.class);
scannerClasses.add(Ordinal.class);
scannerClasses.add(Separator.class);
scannerClasses.add(TimeZone.class);
for (Class scannerClass : scannerClasses) {
try {
tokens = (List<Token>) scannerClass.getMethod("scan", List.class, Options.class).invoke(null, tokens, options);
}
catch (Throwable e) {
throw new RuntimeException("Failed to scan tokens.", e);
}
}
tokens = Grabber.scan(tokens, options);
tokens = Pointer.scan(tokens, options);
tokens = Scalar.scan(tokens, options);
tokens = Ordinal.scan(tokens, options);
tokens = Separator.scan(tokens, options);
tokens = TimeZone.scan(tokens, options);
List<Token> taggedTokens = new LinkedList<Token>();
for (Token token : tokens) {

Binary file not shown.

Binary file not shown.

@ -472,4 +472,11 @@ public class TagViewActivity extends TaskListActivity {
((TextView)taskListView.findViewById(android.R.id.empty)).setText(R.string.TLA_no_items);
}
@Override
protected void refresh() {
setUpMembersGallery();
loadTaskListContent(true);
((TextView)taskListView.findViewById(android.R.id.empty)).setText(R.string.TLA_no_items);
}
}

@ -1019,7 +1019,7 @@ public final class ActFmSyncService {
} else if (id == ActFmPreferenceService.userId()) {
model.setValue(idProperty, 0L);
if (userProperty != null)
model.setValue(userProperty, "");
model.setValue(userProperty, ActFmPreferenceService.thisUser().toString());
} else {
model.setValue(idProperty, id);
if(userProperty != null)

@ -206,17 +206,11 @@ public class GCalControlSet extends PopupControlSet {
@Override
protected void refreshDisplayView() {
TextView t = (TextView) getDisplayView().findViewById(R.id.calendar_display_title);
if (hasEvent) {
t.setText(R.string.gcal_TEA_showCalendar_label);
TextView calendar = (TextView) getDisplayView().findViewById(R.id.calendar_display_which);
if (calendarSelector.getSelectedItemPosition() != 0) {
calendar.setText((String)calendarSelector.getSelectedItem());
} else {
t.setText(R.string.gcal_TEA_addToCalendar_label);
TextView calendar = (TextView) getDisplayView().findViewById(R.id.calendar_display_which);
if (calendarSelector.getSelectedItemPosition() != 0) {
calendar.setText((String)calendarSelector.getSelectedItem());
} else {
calendar.setText("");
}
calendar.setText(R.string.gcal_TEA_none_selected);
}
}

@ -1,16 +1,16 @@
-optimizationpasses 5
-optimizationpasses 2
-dontusemixedcaseclassnames
-dontskipnonpubliclibraryclasses
-dontpreverify
-verbose
-optimizations !code/simplification/arithmetic,!field/*,!class/merging/*,!code/allocation/variable
# astrid-specific
-dontobfuscate
-dontoptimize
-keepattributes SourceFile, SourceDir, LineNumberTable, LocalVariableTable, LocalVariableTypeTable
-keep class com.todoroo.**
-keep, allowshrinking, allowoptimization class com.todoroo.**
-keep class com.mdimension.**
-keepnames class com.google.**
-keep class com.google.common.base.Preconditions
# ignore reflection-based access from google libraries
-dontwarn com.google.**
@ -31,10 +31,6 @@
-keep public class * extends android.app.backup.BackupAgentHelper
-keep public class * extends android.preference.Preference
-keepclasseswithmembernames class * {
native <methods>;
}
-keepclasseswithmembers class * {
public <init>(android.content.Context, android.util.AttributeSet);
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

@ -1,26 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2008 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="false" android:state_enabled="true"
android:state_focused="false" android:drawable="@drawable/header_tasks_normal" />
<item android:state_pressed="true" android:state_enabled="true"
android:drawable="@drawable/header_tasks_pressed" />
<item android:state_pressed="false" android:state_enabled="true"
android:state_focused="true" android:drawable="@drawable/header_tasks_pressed" />
</selector>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 47 KiB

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 48 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 127 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 123 KiB

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 105 KiB

After

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 99 KiB

After

Width:  |  Height:  |  Size: 94 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 80 KiB

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 278 KiB

After

Width:  |  Height:  |  Size: 60 KiB

@ -9,28 +9,21 @@
android:id="@+id/gcal_body"
android:layout_width="fill_parent"
android:layout_height="50dip"
android:paddingLeft="5dip"
android:gravity="center_vertical">
<ImageView
style="@style/EditRowImage"
android:src="@drawable/icn_edit_calendar"/>
<TextView
android:id="@+id/calendar_display_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="15dip"
android:text="@string/gcal_TEA_addToCalendar_label"
style="@style/TextAppearance.GEN_EditLabel.DLG_EditLabel" />
<TextView
android:id="@+id/calendar_display_which"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="right"
android:gravity="left"
android:maxLines="1"
android:ellipsize="end"
android:paddingLeft="10dip"
android:paddingLeft="5dip"
style="@style/TextAppearance.EditRowDisplay" />
<include layout="@layout/task_edit_arrow"/>
</LinearLayout>
<View
android:layout_width="fill_parent"

@ -14,21 +14,18 @@
<ImageView
style="@style/EditRowImage"
android:src="@drawable/icn_edit_repeats"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="15dip"
android:text="@string/repeat_enabled"
style="@style/TextAppearance.GEN_EditLabel.DLG_EditLabel" />
<TextView
android:id="@+id/repeat_display"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="right"
android:paddingLeft="10dip"
android:gravity="left"
android:paddingLeft="5dip"
style="@style/TextAppearance.EditRowDisplay" />
<include layout="@layout/task_edit_arrow"/>
<View
android:layout_width="1px"
android:layout_height="fill_parent"
style="@style/TEA_Separator" />
</LinearLayout>
<View
android:layout_width="fill_parent"

@ -13,10 +13,15 @@
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<LinearLayout
android:id="@+id/datetime_extras"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"/>
<com.todoroo.astrid.ui.CalendarView
android:id="@+id/calendar"
android:layout_width="fill_parent"
android:layout_height="280dip"
android:layout_height="250dip"
android:layout_weight="1" />
<LinearLayout
android:layout_width="fill_parent"

@ -6,8 +6,6 @@
android:layout_height="52dip"
android:paddingTop="2dip"
android:paddingBottom="2dip"
android:paddingLeft="4dip"
android:paddingRight="4dip"
android:orientation="horizontal">
<!-- importance -->

@ -1,15 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- See the file "LICENSE" for the full license governing this code. -->
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
style="@style/Content"
android:orientation="vertical">
<ImageView android:id="@+id/welcome_image"
android:src="@drawable/welcome_android_overlay"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"/>
</RelativeLayout>

@ -15,7 +15,7 @@
android:gravity="center_horizontal"
android:paddingBottom="10dip"
android:layout_marginTop="30dip"
android:text="Connect now\nto get started!"
android:text="@string/welcome_title_7"
android:textColor="#444444"
android:textSize="40dip"
android:textStyle="bold"
@ -47,7 +47,7 @@
android:paddingRight="20dip"
android:paddingBottom="5dip"
android:textSize="16sp"
android:textColor="#ffffff" />
android:textColor="#444444" />
<Button
android:id="@+id/pw_login"
@ -96,6 +96,6 @@
android:paddingLeft="20dip"
android:paddingRight="20dip"
android:textSize="12.5sp"
android:textColor="#ffffff" />
android:textColor="#444444" />
</RelativeLayout>
</LinearLayout>

@ -27,6 +27,8 @@
<!-- No calendar label (don't add option) -->
<string name="gcal_TEA_nocal">Don\'t add</string>
<string name="gcal_TEA_none_selected">Add to cal...</string>
<!-- ======================================================== Calendars == -->
<!-- Calendar event name when task is completed (%s => task title) -->

@ -19,7 +19,7 @@
<!-- hint when opening repeat interval -->
<string name="repeat_interval_prompt">Repeat Interval</string>
<string name="repeat_never">Never</string>
<string name="repeat_never">No Repeat</string>
<string name="repeat_dont">Don\'t repeat</string>

@ -9,7 +9,7 @@
<string name="welcome_title_4">Divvy up tasks</string>
<string name="welcome_title_5">Provide details</string>
<string name="welcome_title_6">Discover</string>
<string name="welcome_title_7">Login</string>
<string name="welcome_title_7">Connect now\nto get started!</string>
<string name="welcome_body_1">The perfect personal\nto-do list that works great\nwith friends</string>
<string name="welcome_body_2">Perfect for any list:\nto read, to watch, to buy,\nto visit, to do!</string>

@ -284,11 +284,11 @@
<item name="android:textColor">@android:color/black</item>
</style>
<style name="CustomCirclePageIndicator">
<item name="fillColor">#FFFFFFFF</item>
<item name="strokeColor">#FF000000</item>
<item name="fillColor">#333333</item>
<item name="strokeColor">#333333</item>
<item name="strokeWidth">2dp</item>
<item name="radius">10dp</item>
<item name="radius">5dp</item>
<item name="centered">true</item>
<item name="android:background">#FFCCCCCC</item>
<item name="android:background">#333333</item>
</style>
</resources>

@ -336,20 +336,20 @@ public final class TaskEditActivity extends Fragment {
RepeatControlSet repeatControls = new RepeatControlSet(
getActivity(), R.layout.control_set_repeat,
R.layout.control_set_repeat_display, R.string.repeat_enabled);
controls.add(repeatControls);
GCalControlSet gcalControl = new GCalControlSet(getActivity(),
R.layout.control_set_gcal, R.layout.control_set_gcal_display,
R.string.gcal_TEA_addToCalendar_label);
//The deadline control set contains the repeat controls and the calendar controls.
//NOTE: we add the gcalControl to the list AFTER the deadline control, because
//NOTE: we add the gcalControl and repeatControl to the list AFTER the deadline control, because
//otherwise the correct date may not be written to the calendar event. Order matters!
DeadlineControlSet deadlineControl = new DeadlineControlSet(
getActivity(), R.layout.control_set_deadline,
R.layout.control_set_deadline_display, repeatControls.getDisplayView(), gcalControl.getDisplayView());
controls.add(deadlineControl);
controlSetMap.put(getString(R.string.TEA_ctrl_when_pref), deadlineControl);
controls.add(repeatControls);
controls.add(gcalControl);
hideUntilControls = new HideUntilControlSet(getActivity(),

@ -114,7 +114,6 @@ import com.todoroo.astrid.utility.Constants;
import com.todoroo.astrid.utility.Flags;
import com.todoroo.astrid.voice.VoiceInputAssistant;
import com.todoroo.astrid.welcome.HelpInfoPopover;
import com.todoroo.astrid.welcome.WelcomeLogin;
import com.todoroo.astrid.welcome.tutorial.WelcomeWalkthrough;
import com.todoroo.astrid.widget.TasksWidget;
@ -635,9 +634,9 @@ public class TaskListActivity extends ListFragment implements OnScrollListener,
new IntentFilter(AstridApiConstants.BROADCAST_SEND_SYNC_ACTIONS));
setUpBackgroundJobs();
if (!Preferences.getBoolean(WelcomeLogin.KEY_SHOWED_WELCOME_LOGIN, false)) {
Preferences.setBoolean(WelcomeLogin.KEY_SHOWED_WELCOME_LOGIN, true);
Intent showWelcomeLogin = new Intent(getActivity(), WelcomeWalkthrough.class);
if (!Preferences.getBoolean(WelcomeWalkthrough.KEY_SHOWED_WELCOME_LOGIN, false)) {
Preferences.setBoolean(WelcomeWalkthrough.KEY_SHOWED_WELCOME_LOGIN, true);
Intent showWelcomeLogin = new Intent(this, WelcomeWalkthrough.class);
showWelcomeLogin.putExtra(ActFmLoginActivity.SHOW_TOAST, false);
startActivity(showWelcomeLogin);
return;

@ -1009,7 +1009,12 @@ public class TaskAdapter extends CursorAdapter implements Filterable {
editTask(taskId);
}
}
fragment.getActivity().unregisterReceiver(this);
try {
fragment.getActivity().unregisterReceiver(this);
} catch (IllegalArgumentException e) {
// ignore
}
}
}

@ -12,7 +12,7 @@ import com.todoroo.astrid.service.SyncV2Service.SyncResultCallback;
public class ProgressBarSyncResultCallback implements SyncResultCallback {
private final ProgressBar progressBar;
private ProgressBar progressBar;
private final Activity activity;
private final Runnable onFinished;
@ -23,6 +23,10 @@ public class ProgressBarSyncResultCallback implements SyncResultCallback {
this.progressBar = (ProgressBar) activity.findViewById(progressBarId);
this.activity = activity;
this.onFinished = onFinished;
if(progressBar == null)
progressBar = new ProgressBar(activity);
progressBar.setProgress(0);
progressBar.setMax(0);
}
@ -33,14 +37,18 @@ public class ProgressBarSyncResultCallback implements SyncResultCallback {
activity.runOnUiThread(new Runnable() {
@Override
public void run() {
progressBar.setMax(100);
progressBar.setProgress(100);
AlphaAnimation animation = new AlphaAnimation(1, 0);
animation.setFillAfter(true);
animation.setDuration(1000L);
progressBar.startAnimation(animation);
try {
progressBar.setMax(100);
progressBar.setProgress(100);
AlphaAnimation animation = new AlphaAnimation(1, 0);
animation.setFillAfter(true);
animation.setDuration(1000L);
progressBar.startAnimation(animation);
onFinished.run();
onFinished.run();
} catch (Exception e) {
// ignore, view could have been destroyed
}
}
});
new Thread() {
@ -50,7 +58,11 @@ public class ProgressBarSyncResultCallback implements SyncResultCallback {
activity.runOnUiThread(new Runnable() {
@Override
public void run() {
progressBar.setVisibility(View.GONE);
try {
progressBar.setVisibility(View.GONE);
} catch (Exception e) {
// ignore
}
}
});
}
@ -63,7 +75,11 @@ public class ProgressBarSyncResultCallback implements SyncResultCallback {
activity.runOnUiThread(new Runnable() {
@Override
public void run() {
progressBar.setMax(progressBar.getMax() + incrementBy);
try {
progressBar.setMax(progressBar.getMax() + incrementBy);
} catch (Exception e) {
// ignore
}
}
});
}
@ -73,7 +89,11 @@ public class ProgressBarSyncResultCallback implements SyncResultCallback {
activity.runOnUiThread(new Runnable() {
@Override
public void run() {
progressBar.incrementProgressBy(incrementBy);
try {
progressBar.incrementProgressBy(incrementBy);
} catch (Exception e) {
// ignore
}
}
});
}

@ -4,6 +4,7 @@ import android.app.Activity;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup.LayoutParams;
import android.widget.Button;
import android.widget.LinearLayout;
import android.widget.TextView;
@ -20,9 +21,10 @@ public class DeadlineControlSet extends PopupControlSet {
super(activity, viewLayout, displayViewLayout, 0);
dateAndTimePicker = (DateAndTimePicker) getView().findViewById(R.id.date_and_time);
LinearLayout body = (LinearLayout) getView().findViewById(R.id.datetime_body);
LinearLayout extras = (LinearLayout) getView().findViewById(R.id.datetime_extras);
for (View v : extraViews) {
body.addView(v);
LayoutParams lp = new LinearLayout.LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT, 1.0f);
extras.addView(v, lp);
}
Button okButton = (Button) LayoutInflater.from(activity).inflate(R.layout.control_dialog_ok, null);
@ -33,6 +35,7 @@ public class DeadlineControlSet extends PopupControlSet {
DialogUtilities.dismissDialog(DeadlineControlSet.this.activity, DeadlineControlSet.this.dialog);
}
});
LinearLayout body = (LinearLayout) getView().findViewById(R.id.datetime_body);
body.addView(okButton);
}

@ -21,7 +21,8 @@ public class EditTitleControlSet extends EditTextControlSet implements Importanc
@Override
public void importanceChanged(int i, int color) {
importance.setImageResource(IMPORTANCE_DRAWABLES[i]);
if(importance != null)
importance.setImageResource(IMPORTANCE_DRAWABLES[i]);
}
}

@ -13,8 +13,9 @@ import android.widget.ImageView;
import android.widget.TextView;
import com.timsu.astrid.R;
import com.viewpagerindicator.TitleProvider;
public class ViewPagerAdapter extends PagerAdapter
public class ViewPagerAdapter extends PagerAdapter implements TitleProvider
{
private static int[] images = new int[]
{
@ -24,7 +25,7 @@ public class ViewPagerAdapter extends PagerAdapter
R.drawable.welcome_walkthrough_4,
R.drawable.welcome_walkthrough_5,
R.drawable.welcome_walkthrough_6,
R.drawable.welcome_screen
0
};
private static int[] title = new int[]
{
@ -120,4 +121,11 @@ public class ViewPagerAdapter extends PagerAdapter
@Override
public void startUpdate( View view ) {}
@Override
public String getTitle(int position) {
return context.getString(title[position]);
}
}

@ -2,7 +2,6 @@
package com.todoroo.astrid.welcome.tutorial;
import android.content.DialogInterface;
import android.content.Intent;
import android.graphics.Color;
import android.os.Bundle;
import android.support.v4.view.ViewPager;
@ -10,7 +9,6 @@ import android.text.SpannableString;
import android.text.Spanned;
import android.text.TextPaint;
import android.text.style.ClickableSpan;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.Window;
@ -21,22 +19,22 @@ import com.timsu.astrid.R;
import com.todoroo.andlib.utility.DialogUtilities;
import com.todoroo.astrid.actfm.ActFmLoginActivity;
import com.todoroo.astrid.activity.Eula;
import com.todoroo.astrid.welcome.WelcomeLogin;
import com.viewpagerindicator.CirclePageIndicator;
import com.viewpagerindicator.PageIndicator;
public class WelcomeWalkthrough extends ActFmLoginActivity {
ViewPager mPager;
ViewPagerAdapter mAdapter;
PageIndicator mIndicator;
View currentView;
int currentPage;
private ViewPager mPager;
private ViewPagerAdapter mAdapter;
private PageIndicator mIndicator;
private View currentView;
private int currentPage;
public static final String KEY_SHOWED_WELCOME_LOGIN = "key_showed_welcome_login"; //$NON-NLS-1$
@Override
protected void onCreate(Bundle savedInstanceState) {
requestWindowFeature(Window.FEATURE_NO_TITLE);
super.onCreate(savedInstanceState);
//setContentView(R.layout.welcome_walkthrough);
mAdapter = new ViewPagerAdapter(this);
mAdapter.parent = this;
@ -57,7 +55,6 @@ public class WelcomeWalkthrough extends ActFmLoginActivity {
return 0;
}
public void pageScrolled(int position, View view){
Log.d(null, "Updated ui");
currentView = view;
currentPage = position;
if (position == mAdapter.getCount()-1) {
@ -90,7 +87,7 @@ public class WelcomeWalkthrough extends ActFmLoginActivity {
@Override
public void updateDrawState(TextPaint ds) {
ds.setUnderlineText(true);
ds.setColor(Color.rgb(255, 255, 255));
ds.setColor(Color.rgb(68, 68, 68));
}
};
link.setSpan(linkSpan, start, link.length() + endOffset, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
@ -129,7 +126,7 @@ public class WelcomeWalkthrough extends ActFmLoginActivity {
@Override
public void updateDrawState(TextPaint ds) {
ds.setUnderlineText(true);
ds.setColor(Color.rgb(255, 255, 255));
ds.setColor(Color.rgb(68, 68, 68));
}
};
loginLaterLink.setSpan(laterSpan, 0, loginLaterBase.length(), Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
@ -142,17 +139,6 @@ public class WelcomeWalkthrough extends ActFmLoginActivity {
Eula.showEulaBasic(WelcomeWalkthrough.this);
}
};
private void showWelcomeLoginActivty() {
Intent showWelcomeLogin = new Intent(this, WelcomeLogin.class);
showWelcomeLogin.putExtra(ActFmLoginActivity.SHOW_TOAST, false);
startActivity(showWelcomeLogin);
}
protected final OnClickListener showWalkthroughLoginListener = new OnClickListener() {
@Override
public void onClick(View v) {
showWelcomeLoginActivty();
}
};
protected final OnClickListener loginLaterListener = new OnClickListener() {
@Override

File diff suppressed because it is too large Load Diff
Loading…
Cancel
Save