fixed wrong icon used when adding a new profile
This commit is contained in:
@@ -77,15 +77,16 @@ android {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compile 'com.android.support:appcompat-v7:23.3.0'
|
||||
compile 'com.android.support:support-v4:23.3.0'
|
||||
compile 'com.android.support:appcompat-v7:23.4.0'
|
||||
compile 'com.android.support:support-v4:23.4.0'
|
||||
compile 'com.squareup.okhttp:okhttp:2.7.5'
|
||||
compile 'com.jakewharton.timber:timber:4.1.2'
|
||||
compile 'com.google.code.gson:gson:2.6.2'
|
||||
compile 'com.jakewharton:butterknife:8.0.1'
|
||||
apt 'com.jakewharton:butterknife-compiler:8.0.1'
|
||||
compile 'net.hockeyapp.android:HockeySDK:4.0.0'
|
||||
compile 'com.koushikdutta.async:androidasync:2.1.7'
|
||||
compile 'com.android.support:design:23.3.0'
|
||||
compile 'com.android.support:design:23.4.0'
|
||||
compile(name: 'holo-color-picker', ext: 'aar')
|
||||
compile 'com.google.guava:guava:19.0'
|
||||
compile 'com.thetransactioncompany:jsonrpc2-base:1.38'
|
||||
|
@@ -74,6 +74,7 @@ import java.util.List;
|
||||
|
||||
import butterknife.BindView;
|
||||
import butterknife.ButterKnife;
|
||||
import timber.log.Timber;
|
||||
|
||||
public class ColorActivity extends AppCompatActivity implements Drawer.OnDrawerItemClickListener, Drawer.OnDrawerItemLongClickListener, OnCheckedChangeListener {
|
||||
|
||||
@@ -106,6 +107,7 @@ public class ColorActivity extends AppCompatActivity implements Drawer.OnDrawerI
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.activity_color);
|
||||
ButterKnife.bind(this);
|
||||
Timber.asTree();
|
||||
|
||||
// check for connectivity
|
||||
ConnectivityManager connMgr = (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);
|
||||
@@ -338,6 +340,8 @@ public class ColorActivity extends AppCompatActivity implements Drawer.OnDrawerI
|
||||
|
||||
@Override
|
||||
public boolean onItemLongClick(View view, int position, IDrawerItem drawerItem) {
|
||||
Timber.d("Longclick of %s", drawerItem.getClass().getName());
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -350,7 +354,7 @@ public class ColorActivity extends AppCompatActivity implements Drawer.OnDrawerI
|
||||
profiles.add(profile);
|
||||
|
||||
List<IDrawerItem> subProfiles = menuProfiles.getSubItems();
|
||||
subProfiles.add(0, new SecondaryDrawerItem().withName(profile.getName()).withSelectable(false).withTag(profile.getValues()).withIcon(R.drawable.ic_save_black_48dp));
|
||||
subProfiles.add(0, new SecondaryDrawerItem().withName(profile.getName()).withSelectable(false).withTag(profile.getValues()).withIcon(R.drawable.ic_note_black_48dp));
|
||||
|
||||
menuProfiles.withSubItems(subProfiles).withIsExpanded(true).withBadge(String.valueOf(profiles.size()));
|
||||
mDrawer.updateItem(menuProfiles);
|
||||
|
Reference in New Issue
Block a user