Skip to content

Commit

Permalink
Further preparation for issue #1
Browse files Browse the repository at this point in the history
  • Loading branch information
obbimi committed Dec 5, 2017
1 parent eabb1be commit c48b110
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
Binary file modified libs/AndroidBase.aar
Binary file not shown.
15 changes: 10 additions & 5 deletions src/com/doubleyellow/scoreboard/dialog/ColorPicker.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
import android.view.ViewGroup;
import android.widget.*;
import com.doubleyellow.android.util.ColorUtil;
import com.doubleyellow.android.view.SatValHueColorPicker;
import com.doubleyellow.scoreboard.R;
import com.doubleyellow.scoreboard.model.Model;
import com.doubleyellow.scoreboard.model.Player;
Expand Down Expand Up @@ -83,16 +84,20 @@ public void init(Player targetPlayer, String sCurrentColor) {
}

private View getColorPickerView() {
ColorPickerView view = new ColorPickerView(context);

//LineColorPicker view = new LineColorPicker(context, null);
View view = new SatValHueColorPicker(context);
if ( false ) {
view = new LineColorPicker(context, null);
}

ViewGroup.LayoutParams layoutParams = new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT);
view.setLayoutParams(layoutParams);

ColorPickerView cpv = (ColorPickerView) view;
if ( this.sColor != null ) {
view.setColor(Color.parseColor(this.sColor));
cpv.setColor(Color.parseColor(this.sColor));
}
view.setOnColorChangedListener(colorChangedListener);
cpv.setOnColorChangedListener(colorChangedListener);

return view;
}

Expand Down

0 comments on commit c48b110

Please sign in to comment.