Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 55133cde authored by Mark Harman's avatar Mark Harman
Browse files

Add icon for night mode extension.

parent 6e54c0eb
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -215,6 +215,7 @@ Also see <i>"Can I use the Open Camera source code in my app?"</i> under the <a
    by Google, under <a href="https://www.apache.org/licenses/LICENSE-2.0.html">Apache license version 2.0</a> (some cases include modifications, no need to credit me).
    In particular:
    baseline_add_a_photo_white_48.png,
    baseline_bedtime_white_48.png
    baseline_bluetooth_white_48.png, baseline_check_white_48.png, baseline_close_white_48.png,
    baseline_delete_white_48.png,
    baseline_face_retouching_natural_white_48.png,
+12 −4
Original line number Diff line number Diff line
@@ -170,6 +170,7 @@ public class DrawPreview {
        // no longer bother with a focus bracketing icon - hard to come up with a clear icon, and should be obvious from the two on-screen seekbars
    private Bitmap burst_bitmap;
    private Bitmap nr_bitmap;
    private Bitmap x_night_bitmap;
    private Bitmap x_bokeh_bitmap;
    private Bitmap x_beauty_bitmap;
    private Bitmap photostamp_bitmap;
@@ -266,6 +267,7 @@ public class DrawPreview {
        //focus_bracket_bitmap = BitmapFactory.decodeResource(getContext().getResources(), R.drawable.focus_bracket_icon);
        burst_bitmap = BitmapFactory.decodeResource(getContext().getResources(), R.drawable.ic_burst_mode_white_48dp);
        nr_bitmap = BitmapFactory.decodeResource(getContext().getResources(), R.drawable.nr_icon);
        x_night_bitmap = BitmapFactory.decodeResource(getContext().getResources(), R.drawable.baseline_bedtime_white_48);
        x_bokeh_bitmap = BitmapFactory.decodeResource(getContext().getResources(), R.drawable.baseline_portrait_white_48);
        x_beauty_bitmap = BitmapFactory.decodeResource(getContext().getResources(), R.drawable.baseline_face_retouching_natural_white_48);
        photostamp_bitmap = BitmapFactory.decodeResource(getContext().getResources(), R.drawable.ic_text_format_white_48dp);
@@ -333,6 +335,10 @@ public class DrawPreview {
            nr_bitmap.recycle();
            nr_bitmap = null;
        }
        if( x_night_bitmap != null ) {
            x_night_bitmap.recycle();
            x_night_bitmap = null;
        }
        if( x_bokeh_bitmap != null ) {
            x_bokeh_bitmap.recycle();
            x_bokeh_bitmap = null;
@@ -1386,6 +1392,7 @@ public class DrawPreview {
                            //photoMode == MyApplicationInterface.PhotoMode.FocusBracketing ||
                            photoMode == MyApplicationInterface.PhotoMode.FastBurst ||
                            photoMode == MyApplicationInterface.PhotoMode.NoiseReduction ||
                            photoMode == MyApplicationInterface.PhotoMode.X_Night ||
                            photoMode == MyApplicationInterface.PhotoMode.X_Bokeh ||
                            photoMode == MyApplicationInterface.PhotoMode.X_Beauty
            ) &&
@@ -1403,6 +1410,7 @@ public class DrawPreview {
                                            //photoMode == MyApplicationInterface.PhotoMode.FocusBracketing ? focus_bracket_bitmap :
                                                    photoMode == MyApplicationInterface.PhotoMode.FastBurst ? burst_bitmap :
                                                            photoMode == MyApplicationInterface.PhotoMode.NoiseReduction ? nr_bitmap :
                                                                    photoMode == MyApplicationInterface.PhotoMode.X_Night ? x_night_bitmap :
                                                                        photoMode == MyApplicationInterface.PhotoMode.X_Bokeh ? x_bokeh_bitmap :
                                                                                photoMode == MyApplicationInterface.PhotoMode.X_Beauty ? x_beauty_bitmap :
                                                                    null;
@@ -1994,8 +2002,8 @@ public class DrawPreview {

            if( preview.supportsZoom() && show_zoom_pref ) {
                float zoom_ratio = preview.getZoomRatio();
                // only show when actually zoomed in
                if( zoom_ratio > 1.0f + 1.0e-5f ) {
                // only show when actually zoomed in - or out!
                if( zoom_ratio < 1.0f - 1.0e-5f || zoom_ratio > 1.0f + 1.0e-5f ) {
                    // Convert the dps to pixels, based on density scale
                    p.setTextSize(14 * scale + 0.5f); // convert dps to pixels
                    p.setTextAlign(Paint.Align.CENTER);
+597 B
Loading image diff...
+428 B
Loading image diff...
+778 B
Loading image diff...
Loading