Search in sources :

Example 1 with BasicParameterStyle

use of com.android.gallery3d.filtershow.controller.BasicParameterStyle in project android_packages_apps_Gallery2 by LineageOS.

the class EditorChanSat method getParameterToEdit.

@Override
protected Parameter getParameterToEdit(FilterRepresentation rep) {
    if (rep instanceof FilterChanSatRepresentation) {
        FilterChanSatRepresentation csrep = (FilterChanSatRepresentation) rep;
        Parameter param = csrep.getFilterParameter(csrep.getParameterMode());
        if (param instanceof BasicParameterStyle) {
            param.setFilterView(EditorChanSat.this);
        }
        return param;
    }
    return null;
}
Also used : Parameter(com.android.gallery3d.filtershow.controller.Parameter) FilterChanSatRepresentation(com.android.gallery3d.filtershow.filters.FilterChanSatRepresentation) BasicParameterStyle(com.android.gallery3d.filtershow.controller.BasicParameterStyle)

Example 2 with BasicParameterStyle

use of com.android.gallery3d.filtershow.controller.BasicParameterStyle in project android_packages_apps_Gallery2 by LineageOS.

the class EditorDrawTabletUI method setDrawRepresentation.

public void setDrawRepresentation(FilterDrawRepresentation rep) {
    mRep = rep;
    BasicParameterInt size;
    size = (BasicParameterInt) mRep.getParam(FilterDrawRepresentation.PARAM_SIZE);
    mdrawSizeSeekBar.setMax(size.getMaximum() - size.getMinimum());
    mdrawSizeSeekBar.setProgress(size.getValue());
    ParameterColor color;
    color = (ParameterColor) mRep.getParam(FilterDrawRepresentation.PARAM_COLOR);
    color.setValue(mBasColors[mSelectedColorButton]);
    BasicParameterStyle style;
    style = (BasicParameterStyle) mRep.getParam(FilterDrawRepresentation.PARAM_STYLE);
    style.setSelected(mSelectedStyleButton);
}
Also used : BasicParameterInt(com.android.gallery3d.filtershow.controller.BasicParameterInt) ParameterColor(com.android.gallery3d.filtershow.controller.ParameterColor) BasicParameterStyle(com.android.gallery3d.filtershow.controller.BasicParameterStyle)

Aggregations

BasicParameterStyle (com.android.gallery3d.filtershow.controller.BasicParameterStyle)2 BasicParameterInt (com.android.gallery3d.filtershow.controller.BasicParameterInt)1 Parameter (com.android.gallery3d.filtershow.controller.Parameter)1 ParameterColor (com.android.gallery3d.filtershow.controller.ParameterColor)1 FilterChanSatRepresentation (com.android.gallery3d.filtershow.filters.FilterChanSatRepresentation)1