Updated to new menu drawer build

This commit is contained in:
Joshua Bahnsen 2013-06-11 02:51:50 -07:00
parent 0050b69a36
commit 191d280020
14 changed files with 16 additions and 11 deletions

View File

@ -10,5 +10,6 @@
# Project target. # Project target.
target=android-17 target=android-17
android.library=false android.library=false
android.library.reference.1=android-menudrawer-master/library
android.library.reference.2=Android-PullToRefresh/library android.library.reference.1=pulltorefresh/library
android.library.reference.2=menudrawer/library

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 800 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 840 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 929 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 830 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1022 B

View File

@ -73,7 +73,7 @@ public final class HelpActivity extends Activity implements OnClickListener {
menuActiveViewId = bundle.getInt(STATE_ACTIVE_VIEW_ID); menuActiveViewId = bundle.getInt(STATE_ACTIVE_VIEW_ID);
} }
menuDrawer = MenuDrawer.attach(this, MenuDrawer.MENU_DRAG_WINDOW, Position.LEFT); menuDrawer = MenuDrawer.attach(this, MenuDrawer.Type.BEHIND, Position.LEFT, MenuDrawer.MENU_DRAG_WINDOW);
menuDrawer.setMenuView(R.layout.menu_main); menuDrawer.setMenuView(R.layout.menu_main);
chatMenuItem = findViewById(R.id.menu_chat); chatMenuItem = findViewById(R.id.menu_chat);
@ -201,7 +201,7 @@ public final class HelpActivity extends Activity implements OnClickListener {
final int drawerState = menuDrawer.getDrawerState(); final int drawerState = menuDrawer.getDrawerState();
if (drawerState == MenuDrawer.STATE_OPEN || drawerState == MenuDrawer.STATE_OPENING) { if (drawerState == MenuDrawer.STATE_OPEN || drawerState == MenuDrawer.STATE_OPENING) {
menuDrawer.closeMenu(); menuDrawer.closeMenu(true);
return; return;
} }
@ -213,11 +213,13 @@ public final class HelpActivity extends Activity implements OnClickListener {
@Override @Override
public void onClick(View v) { public void onClick(View v) {
menuActiveViewId = v.getId(); menuActiveViewId = v.getId();
menuDrawer.setActiveView(v);
Intent intent; Intent intent;
switch (menuActiveViewId) { switch (menuActiveViewId) {
case R.id.menu_home: case R.id.menu_home:
intent = new Intent(this, MainActivity.class); intent = new Intent(this, MainActivity.class);
intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP); intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
Util.startActivityWithoutTransition(this, intent); Util.startActivityWithoutTransition(this, intent);
@ -260,7 +262,7 @@ public final class HelpActivity extends Activity implements OnClickListener {
break; break;
} }
menuDrawer.closeMenu(); menuDrawer.closeMenu(true);
} }
private final class HelpClient extends WebViewClient { private final class HelpClient extends WebViewClient {

View File

@ -114,7 +114,7 @@ public class SettingsActivity extends PreferenceActivity implements SharedPrefer
menuActiveViewId = savedInstanceState.getInt(STATE_ACTIVE_VIEW_ID); menuActiveViewId = savedInstanceState.getInt(STATE_ACTIVE_VIEW_ID);
} }
menuDrawer = MenuDrawer.attach(this, MenuDrawer.MENU_DRAG_WINDOW, Position.LEFT); menuDrawer = MenuDrawer.attach(this, MenuDrawer.Type.BEHIND, Position.LEFT, MenuDrawer.MENU_DRAG_WINDOW);
menuDrawer.setMenuView(R.layout.menu_main); menuDrawer.setMenuView(R.layout.menu_main);
chatMenuItem = findViewById(R.id.menu_chat); chatMenuItem = findViewById(R.id.menu_chat);
@ -641,7 +641,7 @@ public class SettingsActivity extends PreferenceActivity implements SharedPrefer
final int drawerState = menuDrawer.getDrawerState(); final int drawerState = menuDrawer.getDrawerState();
if (drawerState == MenuDrawer.STATE_OPEN || drawerState == MenuDrawer.STATE_OPENING) { if (drawerState == MenuDrawer.STATE_OPEN || drawerState == MenuDrawer.STATE_OPENING) {
menuDrawer.closeMenu(); menuDrawer.closeMenu(true);
return; return;
} }
@ -651,6 +651,7 @@ public class SettingsActivity extends PreferenceActivity implements SharedPrefer
@Override @Override
public void onClick(View v) { public void onClick(View v) {
menuActiveViewId = v.getId(); menuActiveViewId = v.getId();
menuDrawer.setActiveView(v);
Intent intent; Intent intent;
@ -698,6 +699,6 @@ public class SettingsActivity extends PreferenceActivity implements SharedPrefer
break; break;
} }
menuDrawer.closeMenu(); menuDrawer.closeMenu(true);
} }
} }

View File

@ -114,7 +114,7 @@ public class SubsonicTabActivity extends Activity implements OnClickListener{
menuActiveViewId = bundle.getInt(STATE_ACTIVE_VIEW_ID); menuActiveViewId = bundle.getInt(STATE_ACTIVE_VIEW_ID);
} }
menuDrawer = MenuDrawer.attach(this, MenuDrawer.MENU_DRAG_WINDOW, Position.LEFT); menuDrawer = MenuDrawer.attach(this, MenuDrawer.Type.BEHIND, Position.LEFT, MenuDrawer.MENU_DRAG_WINDOW);
menuDrawer.setMenuView(R.layout.menu_main); menuDrawer.setMenuView(R.layout.menu_main);
chatMenuItem = findViewById(R.id.menu_chat); chatMenuItem = findViewById(R.id.menu_chat);
@ -912,6 +912,7 @@ public class SubsonicTabActivity extends Activity implements OnClickListener{
@Override @Override
public void onClick(View v) { public void onClick(View v) {
menuActiveViewId = v.getId(); menuActiveViewId = v.getId();
menuDrawer.setActiveView(v);
Intent intent; Intent intent;
@ -959,7 +960,7 @@ public class SubsonicTabActivity extends Activity implements OnClickListener{
break; break;
} }
menuDrawer.closeMenu(); menuDrawer.closeMenu(true);
} }
@Override @Override
@ -981,7 +982,7 @@ public class SubsonicTabActivity extends Activity implements OnClickListener{
final int drawerState = menuDrawer.getDrawerState(); final int drawerState = menuDrawer.getDrawerState();
if (drawerState == MenuDrawer.STATE_OPEN || drawerState == MenuDrawer.STATE_OPENING) { if (drawerState == MenuDrawer.STATE_OPEN || drawerState == MenuDrawer.STATE_OPENING) {
menuDrawer.closeMenu(); menuDrawer.closeMenu(true);
return; return;
} }