updated holo-color-picker

removed some debug out
This commit is contained in:
2016-05-01 22:03:22 +02:00
parent ab2c219dca
commit 9d043c21a3
6 changed files with 7 additions and 13 deletions

View File

@@ -42,6 +42,12 @@ apply plugin: 'com.jakewharton.hugo'
apply plugin: 'com.github.ben-manes.versions' apply plugin: 'com.github.ben-manes.versions'
apply plugin: 'com.neenbedankt.android-apt' apply plugin: 'com.neenbedankt.android-apt'
repositories {
flatDir {
dirs 'aars'
}
}
android { android {
compileSdkVersion 23 compileSdkVersion 23
buildToolsVersion '23.0.3' buildToolsVersion '23.0.3'
@@ -71,7 +77,6 @@ android {
} }
dependencies { dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:appcompat-v7:23.3.0' compile 'com.android.support:appcompat-v7:23.3.0'
compile 'com.android.support:support-v4:23.3.0' compile 'com.android.support:support-v4:23.3.0'
compile 'com.squareup.okhttp:okhttp:2.7.5' compile 'com.squareup.okhttp:okhttp:2.7.5'
@@ -81,7 +86,7 @@ dependencies {
compile 'net.hockeyapp.android:HockeySDK:4.0.0' compile 'net.hockeyapp.android:HockeySDK:4.0.0'
compile 'com.koushikdutta.async:androidasync:2.1.7' compile 'com.koushikdutta.async:androidasync:2.1.7'
compile 'com.android.support:design:23.3.0' compile 'com.android.support:design:23.3.0'
compile 'com.larswerkman:HoloColorPicker:1.5@aar' compile(name: 'holo-color-picker', ext: 'aar')
compile 'com.google.guava:guava:19.0' compile 'com.google.guava:guava:19.0'
compile 'com.thetransactioncompany:jsonrpc2-base:1.38' compile 'com.thetransactioncompany:jsonrpc2-base:1.38'
compile('com.mikepenz:materialdrawer:5.2.2@aar') { compile('com.mikepenz:materialdrawer:5.2.2@aar') {

Binary file not shown.

View File

@@ -74,7 +74,6 @@ import java.util.List;
import butterknife.BindView; import butterknife.BindView;
import butterknife.ButterKnife; import butterknife.ButterKnife;
import hugo.weaving.DebugLog;
public class ColorActivity extends AppCompatActivity implements Drawer.OnDrawerItemClickListener, Drawer.OnDrawerItemLongClickListener, OnCheckedChangeListener { public class ColorActivity extends AppCompatActivity implements Drawer.OnDrawerItemClickListener, Drawer.OnDrawerItemLongClickListener, OnCheckedChangeListener {
@@ -346,7 +345,6 @@ public class ColorActivity extends AppCompatActivity implements Drawer.OnDrawerI
return ledStripes; return ledStripes;
} }
@DebugLog
public void addProfile(Profile profile) { public void addProfile(Profile profile) {
if (profiles != null) { if (profiles != null) {
profiles.add(profile); profiles.add(profile);
@@ -486,7 +484,6 @@ public class ColorActivity extends AppCompatActivity implements Drawer.OnDrawerI
isRefreshRunning = false; isRefreshRunning = false;
} }
@DebugLog
private void selectStripe(LedStripe stripe) { private void selectStripe(LedStripe stripe) {
mCurrentStripe = stripe; mCurrentStripe = stripe;
@@ -528,7 +525,6 @@ public class ColorActivity extends AppCompatActivity implements Drawer.OnDrawerI
} }
@Nullable @Nullable
@DebugLog
private IDrawerItem findItemForStripe(LedStripe stripe) { private IDrawerItem findItemForStripe(LedStripe stripe) {
for (IDrawerItem dItem : mDaemons) { for (IDrawerItem dItem : mDaemons) {
if (((PrimaryDrawerItem) dItem).getSubItems() != null) { if (((PrimaryDrawerItem) dItem).getSubItems() != null) {

View File

@@ -25,7 +25,6 @@ import com.idlegandalf.ledd.ColorApplication;
import com.idlegandalf.ledd.callbacks.ReceiveColorCallback; import com.idlegandalf.ledd.callbacks.ReceiveColorCallback;
import com.idlegandalf.ledd.helper.LedDHelper; import com.idlegandalf.ledd.helper.LedDHelper;
import hugo.weaving.DebugLog;
import lombok.Getter; import lombok.Getter;
import lombok.Setter; import lombok.Setter;
@@ -70,7 +69,6 @@ public class LedStripe {
return String.format("%s->%s->%s (%d|%d|%d)", ledDDaemon, controller.getAddress(), name, channelRed, channelGreen, channelBlue); return String.format("%s->%s->%s (%d|%d|%d)", ledDDaemon, controller.getAddress(), name, channelRed, channelGreen, channelBlue);
} }
@DebugLog
public void setColor(int color) { public void setColor(int color) {
float[] hsv = new float[3]; float[] hsv = new float[3];
Color.colorToHSV(color, hsv); Color.colorToHSV(color, hsv);
@@ -90,7 +88,6 @@ public class LedStripe {
} }
} }
@DebugLog
public void getColor(@Nullable final ReceiveColorCallback callback) { public void getColor(@Nullable final ReceiveColorCallback callback) {
checkHelper(); checkHelper();
@@ -114,7 +111,6 @@ public class LedStripe {
}); });
} }
@DebugLog
public boolean isOn() { public boolean isOn() {
return color != null && color.getValue() != 0.0; return color != null && color.getValue() != 0.0;
} }

View File

@@ -42,7 +42,6 @@ import java.util.List;
import butterknife.BindView; import butterknife.BindView;
import butterknife.ButterKnife; import butterknife.ButterKnife;
import hugo.weaving.DebugLog;
public class AddProfileDialog extends DialogFragment implements DialogInterface.OnShowListener { public class AddProfileDialog extends DialogFragment implements DialogInterface.OnShowListener {
@@ -56,7 +55,6 @@ public class AddProfileDialog extends DialogFragment implements DialogInterface.
List<LedStripe> mStripes; List<LedStripe> mStripes;
List<CheckBox> mCheckboxes; List<CheckBox> mCheckboxes;
@DebugLog
public Dialog onCreateDialog(Bundle savedInstanceState) { public Dialog onCreateDialog(Bundle savedInstanceState) {
View v = View.inflate(getActivity(), R.layout.fragment_addprofile, null); View v = View.inflate(getActivity(), R.layout.fragment_addprofile, null);
ButterKnife.bind(this, v); ButterKnife.bind(this, v);

View File

@@ -232,7 +232,6 @@ public class LedDHelper {
JSONObject json = new JSONObject(response.getResult().toString()); JSONObject json = new JSONObject(response.getResult().toString());
JSONArray hsv = json.getJSONArray("color"); JSONArray hsv = json.getJSONArray("color");
if (hsv.length() == 3) { if (hsv.length() == 3) {
System.out.println(hsv);
ledStripe.setColor(new HSV(hsv.getDouble(0), hsv.getDouble(1), hsv.getDouble(2))); ledStripe.setColor(new HSV(hsv.getDouble(0), hsv.getDouble(1), hsv.getDouble(2)));
callback.onColorReceived(ledStripe); callback.onColorReceived(ledStripe);
} else { } else {