mirror of
https://github.com/peterosterlund2/droidfish.git
synced 2025-12-21 13:12:17 +01:00
DroidFish: Fixed lint warning.
This commit is contained in:
@@ -24,6 +24,7 @@ import android.graphics.PixelFormat;
|
|||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.view.LayoutInflater;
|
import android.view.LayoutInflater;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
import android.widget.LinearLayout;
|
import android.widget.LinearLayout;
|
||||||
|
|
||||||
public class ColorPickerDialog
|
public class ColorPickerDialog
|
||||||
@@ -62,19 +63,14 @@ public class ColorPickerDialog
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void setUp(int color) {
|
private void setUp(int color) {
|
||||||
|
setContentView(R.layout.dialog_color_picker);
|
||||||
LayoutInflater inflater = (LayoutInflater) getContext().getSystemService(Context.LAYOUT_INFLATER_SERVICE);
|
|
||||||
|
|
||||||
View layout = inflater.inflate(R.layout.dialog_color_picker, null);
|
|
||||||
|
|
||||||
setContentView(layout);
|
|
||||||
|
|
||||||
setTitle(getContext().getText(R.string.prefs_colors_title) + " '"
|
setTitle(getContext().getText(R.string.prefs_colors_title) + " '"
|
||||||
+ additionalInfo + "'");
|
+ additionalInfo + "'");
|
||||||
|
|
||||||
mColorPicker = (ColorPickerView) layout.findViewById(R.id.color_picker_view);
|
mColorPicker = (ColorPickerView) findViewById(R.id.color_picker_view);
|
||||||
mOldColor = (ColorPickerPanelView) layout.findViewById(R.id.old_color_panel);
|
mOldColor = (ColorPickerPanelView) findViewById(R.id.old_color_panel);
|
||||||
mNewColor = (ColorPickerPanelView) layout.findViewById(R.id.new_color_panel);
|
mNewColor = (ColorPickerPanelView) findViewById(R.id.new_color_panel);
|
||||||
|
|
||||||
((LinearLayout) mOldColor.getParent()).setPadding(
|
((LinearLayout) mOldColor.getParent()).setPadding(
|
||||||
Math.round(mColorPicker.getDrawingOffset()),
|
Math.round(mColorPicker.getDrawingOffset()),
|
||||||
|
|||||||
Reference in New Issue
Block a user