com.flask.colorpicker.builder.ColorWheelRendererBuilder Java Examples
The following examples show how to use
com.flask.colorpicker.builder.ColorWheelRendererBuilder.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: ColorPickerView.java From java-n-IDE-for-Android with Apache License 2.0 | 6 votes |
private void initWith(Context context, AttributeSet attrs) { final TypedArray typedArray = context.obtainStyledAttributes(attrs, R.styleable.ColorPickerPreference); density = typedArray.getInt(R.styleable.ColorPickerPreference_density, 10); initialColor = typedArray.getInt(R.styleable.ColorPickerPreference_initialColor, 0xffffffff); pickerTextColor = typedArray.getInt(R.styleable.ColorPickerPreference_pickerColorEditTextColor, 0xffffffff); WHEEL_TYPE wheelType = WHEEL_TYPE.indexOf(typedArray.getInt(R.styleable.ColorPickerPreference_wheelType, 0)); ColorWheelRenderer renderer = ColorWheelRendererBuilder.getRenderer(wheelType); alphaSliderViewId = typedArray.getResourceId(R.styleable.ColorPickerPreference_alphaSliderView, 0); lightnessSliderViewId = typedArray.getResourceId(R.styleable.ColorPickerPreference_lightnessSliderView, 0); setRenderer(renderer); setDensity(density); setInitialColor(initialColor, true); typedArray.recycle(); }
Example #2
Source File: ColorPickerView.java From timecat with Apache License 2.0 | 6 votes |
private void initWith(Context context, AttributeSet attrs) { final TypedArray typedArray = context.obtainStyledAttributes(attrs, R.styleable.ColorPickerPreference); density = typedArray.getInt(R.styleable.ColorPickerPreference_density, 10); initialColor = typedArray.getInt(R.styleable.ColorPickerPreference_initialColor, 0xffffffff); pickerTextColor = typedArray.getInt(R.styleable.ColorPickerPreference_pickerColorEditTextColor, 0xffffffff); WHEEL_TYPE wheelType = WHEEL_TYPE.indexOf(typedArray.getInt(R.styleable.ColorPickerPreference_wheelType, 0)); ColorWheelRenderer renderer = ColorWheelRendererBuilder.getRenderer(wheelType); alphaSliderViewId = typedArray.getResourceId(R.styleable.ColorPickerPreference_alphaSliderView, 0); lightnessSliderViewId = typedArray.getResourceId(R.styleable.ColorPickerPreference_lightnessSliderView, 0); setRenderer(renderer); setDensity(density); setInitialColor(initialColor, true); typedArray.recycle(); }
Example #3
Source File: ColorPickerView.java From javaide with GNU General Public License v3.0 | 6 votes |
private void initWith(Context context, AttributeSet attrs) { final TypedArray typedArray = context.obtainStyledAttributes(attrs, R.styleable.ColorPickerPreference); density = typedArray.getInt(R.styleable.ColorPickerPreference_density, 10); initialColor = typedArray.getInt(R.styleable.ColorPickerPreference_initialColor, 0xffffffff); pickerTextColor = typedArray.getInt(R.styleable.ColorPickerPreference_pickerColorEditTextColor, 0xffffffff); WHEEL_TYPE wheelType = WHEEL_TYPE.indexOf(typedArray.getInt(R.styleable.ColorPickerPreference_wheelType, 0)); ColorWheelRenderer renderer = ColorWheelRendererBuilder.getRenderer(wheelType); alphaSliderViewId = typedArray.getResourceId(R.styleable.ColorPickerPreference_alphaSliderView, 0); lightnessSliderViewId = typedArray.getResourceId(R.styleable.ColorPickerPreference_lightnessSliderView, 0); setRenderer(renderer); setDensity(density); setInitialColor(initialColor, true); typedArray.recycle(); }
Example #4
Source File: ColorPickerView.java From openlauncher with Apache License 2.0 | 6 votes |
private void initWith(Context context, AttributeSet attrs) { final TypedArray typedArray = context.obtainStyledAttributes(attrs, R.styleable.ColorPickerPreference); density = typedArray.getInt(R.styleable.ColorPickerPreference_density, 10); initialColor = typedArray.getInt(R.styleable.ColorPickerPreference_initialColor, 0xffffffff); pickerColorEditTextColor = typedArray.getInt(R.styleable.ColorPickerPreference_pickerColorEditTextColor, 0xffffffff); WHEEL_TYPE wheelType = WHEEL_TYPE.indexOf(typedArray.getInt(R.styleable.ColorPickerPreference_wheelType, 0)); ColorWheelRenderer renderer = ColorWheelRendererBuilder.getRenderer(wheelType); alphaSliderViewId = typedArray.getResourceId(R.styleable.ColorPickerPreference_alphaSliderView, 0); lightnessSliderViewId = typedArray.getResourceId(R.styleable.ColorPickerPreference_lightnessSliderView, 0); setRenderer(renderer); setDensity(density); setInitialColor(initialColor, true); typedArray.recycle(); }
Example #5
Source File: ColorPickerView.java From droidddle with Apache License 2.0 | 5 votes |
private void initWith(Context context, AttributeSet attrs) { final TypedArray typedArray = context.obtainStyledAttributes(attrs, R.styleable.ColorPickerPreference); density = typedArray.getInt(R.styleable.ColorPickerPreference_density, 10); initialColor = typedArray.getInt(R.styleable.ColorPickerPreference_initialColor, 0xffffffff); WHEEL_TYPE wheelType = WHEEL_TYPE.indexOf(typedArray.getInt(R.styleable.ColorPickerPreference_wheelType, 0)); ColorWheelRenderer renderer = ColorWheelRendererBuilder.getRenderer(wheelType); alphaSliderViewId = typedArray.getResourceId(R.styleable.ColorPickerPreference_alphaSliderView, 0); lightnessSliderViewId = typedArray.getResourceId(R.styleable.ColorPickerPreference_lightnessSliderView, 0); setRenderer(renderer); setDensity(density); setInitialColor(initialColor); }