initial commit

This commit is contained in:
NudeDude 2017-11-05 23:59:40 +01:00
parent a485e5659e
commit 6eb6c4defe
6 changed files with 26 additions and 23 deletions

View File

@ -24,7 +24,7 @@
</value>
</option>
</component>
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_7" default="true" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/build/classes" />
</component>
<component name="ProjectType">

View File

@ -28,6 +28,7 @@ public class MainActivity extends Activity
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
getActionBar().setDisplayShowTitleEnabled(false);
einstellungen = getApplicationContext().getSharedPreferences("settings", 0);
con = getApplicationContext();
if( !loggedIn() ) {

View File

@ -67,16 +67,16 @@ public class TwitterEngine extends AsyncTask<Integer, Void, Void>
@Override
protected void onPostExecute(Void v) {
if(list.getAdapter()==null) {
if(timelineAdapter != null) {
list.setAdapter(timelineAdapter);
timelineAdapter.notifyDataSetChanged();
}
else if(trendsAdapter != null) {
list.setAdapter(trendsAdapter);
trendsAdapter.notifyDataSetChanged();
}
if(timelineAdapter != null) {
list.setAdapter(timelineAdapter);
timelineAdapter.notifyDataSetChanged();
}
else if(trendsAdapter != null) {
list.setAdapter(trendsAdapter);
trendsAdapter.notifyDataSetChanged();
}
if(refresh != null)
refresh.setRefreshing(false);

View File

@ -8,7 +8,7 @@
<TextView
android:id="@+id/trendname"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
android:layout_height="match_parent" />
</LinearLayout>

View File

@ -56,6 +56,7 @@
android:layout_height="32dp"
android:layout_weight="1"
android:addStatesFromChildren="false"
android:gravity="right"
android:orientation="horizontal">
<Button
@ -70,18 +71,6 @@
android:layout_height="match_parent"
android:ems="10" />
<Button
android:id="@+id/favorite"
android:layout_width="32dp"
android:layout_height="match_parent"
android:background="@drawable/star" />
<TextView
android:id="@+id/favorite_number"
android:layout_width="64dp"
android:layout_height="match_parent"
android:ems="10" />
<Button
android:id="@+id/retweet"
android:layout_width="32dp"
@ -94,6 +83,18 @@
android:layout_height="match_parent"
android:ems="10" />
<Button
android:id="@+id/favorite"
android:layout_width="32dp"
android:layout_height="match_parent"
android:background="@drawable/star" />
<TextView
android:id="@+id/favorite_number"
android:layout_width="64dp"
android:layout_height="match_parent"
android:ems="10" />
</LinearLayout>
</LinearLayout>

View File

@ -6,6 +6,7 @@
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
</style>
</resources>