Skip to content

Commit a54d5a8

Browse files
committed
updates
1 parent db381d8 commit a54d5a8

File tree

60 files changed

+706
-13
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+706
-13
lines changed

android.jfokus.actionbar/res/menu/main.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!--
1+
android.widget.ShareActionProvider<!--
22
Copyright 2011 The Android Open Source Project
33
44
Licensed under the Apache License, Version 2.0 (the "License");
Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,16 @@
11
<menu xmlns:android="http://schemas.android.com/apk/res/android" >
22

33
<item
4-
android:id="@+id/menuitem_refresh"
4+
android:id="@+id/action_refresh"
55
android:orderInCategory="100"
66
android:showAsAction="always"
77
android:icon="@drawable/ic_action_search"
88
android:title="Refresh"/>
99
<item
10-
android:id="@+id/menuitem_settings"
11-
android:title="Settings">
10+
android:id="@+id/action_settings"
11+
android:title="Settings"
12+
android:showAsAction="never"
13+
>
1214
</item>
1315

1416
</menu>

com.example.android.rssfeed/src/com/example/android/rssfeed/RssfeedActivity.java

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,10 @@
55
import android.os.Bundle;
66
import android.view.Menu;
77
import android.view.MenuItem;
8+
import android.widget.Toast;
89

9-
public class RssfeedActivity extends Activity {
10+
public class RssfeedActivity extends Activity implements
11+
MyListFragment.OnItemSelectedListener {
1012

1113
@Override
1214
public void onCreate(Bundle savedInstanceState) {
@@ -16,7 +18,7 @@ public void onCreate(Bundle savedInstanceState) {
1618
// .permitAll().build();
1719
// StrictMode.setThreadPolicy(policy);
1820

19-
setContentView(R.layout.activity_rssfeed);
21+
// setContentView(R.layout.activity_rssfeed);
2022
}
2123

2224
@Override
@@ -29,12 +31,13 @@ public boolean onCreateOptionsMenu(Menu menu) {
2931
public boolean onOptionsItemSelected(MenuItem item) {
3032
switch (item.getItemId()) {
3133

32-
case R.id.menuitem_refresh:
33-
MyListFragment fragment = (MyListFragment) getFragmentManager()
34-
.findFragmentById(R.id.listFragment);
35-
// fragment.updateListContent();
34+
case R.id.action_refresh:
35+
Toast.makeText(this, "Action refresh selected", Toast.LENGTH_SHORT)
36+
.show();
37+
// MyListFragment fragment = (MyListFragment) getFragmentManager()
38+
// .findFragmentById(R.id.listFragment);
3639
break;
37-
case R.id.menuitem_settings:
40+
case R.id.action_settings:
3841
Intent intent = new Intent(this, MyPreferenceActivity.class);
3942
startActivity(intent);
4043
break;
@@ -43,4 +46,10 @@ public boolean onOptionsItemSelected(MenuItem item) {
4346
}
4447
return true;
4548
}
49+
50+
@Override
51+
public void onRssItemSelected(String link) {
52+
// TODO Auto-generated method stub
53+
54+
}
4655
}

com.example.android.rssfeedlibrary/project.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,5 @@
1111
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
1212

1313
# Project target.
14-
target=android-16
14+
target=android-17
1515
android.library=true
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<classpath>
3+
<classpathentry kind="src" path="src"/>
4+
<classpathentry kind="src" path="gen"/>
5+
<classpathentry kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
6+
<classpathentry kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/>
7+
<classpathentry kind="output" path="bin/classes"/>
8+
</classpath>
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<projectDescription>
3+
<name>com.vogella.android.actionbar.actionprovider</name>
4+
<comment></comment>
5+
<projects>
6+
</projects>
7+
<buildSpec>
8+
<buildCommand>
9+
<name>com.android.ide.eclipse.adt.ResourceManagerBuilder</name>
10+
<arguments>
11+
</arguments>
12+
</buildCommand>
13+
<buildCommand>
14+
<name>com.android.ide.eclipse.adt.PreCompilerBuilder</name>
15+
<arguments>
16+
</arguments>
17+
</buildCommand>
18+
<buildCommand>
19+
<name>org.eclipse.jdt.core.javabuilder</name>
20+
<arguments>
21+
</arguments>
22+
</buildCommand>
23+
<buildCommand>
24+
<name>com.android.ide.eclipse.adt.ApkBuilder</name>
25+
<arguments>
26+
</arguments>
27+
</buildCommand>
28+
</buildSpec>
29+
<natures>
30+
<nature>com.android.ide.eclipse.adt.AndroidNature</nature>
31+
<nature>org.eclipse.jdt.core.javanature</nature>
32+
</natures>
33+
</projectDescription>
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
3+
package="com.example.com.vogella.android.actionbar.actionprovider"
4+
android:versionCode="1"
5+
android:versionName="1.0" >
6+
7+
<uses-sdk
8+
android:minSdkVersion="17"
9+
android:targetSdkVersion="17" />
10+
11+
<application
12+
android:allowBackup="true"
13+
android:icon="@drawable/ic_launcher"
14+
android:label="@string/app_name"
15+
android:theme="@style/AppTheme" >
16+
<activity
17+
android:name="com.example.com.vogella.android.actionbar.actionprovider.MainActivity"
18+
android:label="@string/app_name" >
19+
<intent-filter>
20+
<action android:name="android.intent.action.MAIN" />
21+
22+
<category android:name="android.intent.category.LAUNCHER" />
23+
</intent-filter>
24+
</activity>
25+
</application>
26+
27+
</manifest>
54.4 KB
Loading
Binary file not shown.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# To enable ProGuard in your project, edit project.properties
2+
# to define the proguard.config property as described in that file.
3+
#
4+
# Add project specific ProGuard rules here.
5+
# By default, the flags in this file are appended to flags specified
6+
# in ${sdk.dir}/tools/proguard/proguard-android.txt
7+
# You can edit the include path and order by changing the ProGuard
8+
# include property in project.properties.
9+
#
10+
# For more details, see
11+
# http://developer.android.com/guide/developing/tools/proguard.html
12+
13+
# Add any project specific keep options here:
14+
15+
# If your project uses WebView with JS, uncomment the following
16+
# and specify the fully qualified class name to the JavaScript interface
17+
# class:
18+
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
19+
# public *;
20+
#}

0 commit comments

Comments
 (0)