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

Commit aed50cbe authored by Michael Bestas's avatar Michael Bestas Committed by AdrianDC
Browse files

Add CM PlatLogo (1/2)

* Icons by: Björn Lundén & Asher Simonds

Change-Id: Ie2b092bafd3588270177648003dafed8226cf298
parent 0dc882ea
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
/*
 * Copyright (C) 2010 The Android Open Source Project
 * Copyright (C) 2014-2015 The CyanogenMod Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
@@ -57,10 +58,13 @@ public class PlatLogoActivity extends Activity {
    int mKeyCount;
    PathInterpolator mInterpolator = new PathInterpolator(0f, 0f, 0.5f, 1f);

    private boolean mIsCM;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        mIsCM = getIntent().hasExtra("is_cm");
        mLayout = new FrameLayout(this);
        setContentView(mLayout);
    }
@@ -153,6 +157,7 @@ public class PlatLogoActivity extends Activity {
                                            .setFlags(Intent.FLAG_ACTIVITY_NEW_TASK
                                                    | Intent.FLAG_ACTIVITY_CLEAR_TASK
                                                    | Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS)
                                            .putExtra("is_cm", mIsCM)
                                            .addCategory("com.android.internal.category.PLATLOGO"));
                                } catch (ActivityNotFoundException ex) {
                                    Log.e("PlatLogoActivity", "No more eggs.");
@@ -202,7 +207,9 @@ public class PlatLogoActivity extends Activity {
    }

    public void showMarshmallow(View im) {
        final Drawable fg = getDrawable(com.android.internal.R.drawable.platlogo);
        final Drawable fg = getDrawable(mIsCM
                ? com.android.internal.R.drawable.platlogo_cm
                : com.android.internal.R.drawable.platlogo);
        fg.setBounds(0, 0, im.getWidth(), im.getHeight());
        fg.setAlpha(0);
        im.getOverlay().add(fg);
+55 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
    Copyright (c) 2015 The CyanogenMod Project

    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

        http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
    android:width="48dp"
    android:height="48dp"
    android:viewportWidth="48.0"
    android:viewportHeight="48.0">

    <path
        android:name="body"
        android:fillColor="#FFFFFF"
        android:pathData="M24,12L24,12L24,12L24,12L24,12c7.7,0,14,1.2,14.9,2.6c0,0,0,0,0,0c1,1.5,1.1,6.5,1.1,9.4s-0.1,7.8-1.1,9.4
c0,0,0,0,0,0C38,34.8,31.7,36,24,36l0,0l0,0l0,0l0,0l0,0l0,0l0,0l0,0c-7.7,0-14-1.2-14.9-2.6c0,0,0,0,0,0C8.1,31.8,8,26.9,8,24
s0.1-7.8,1.1-9.4c0,0,0,0,0,0C10,13.2,16.3,12,24,12L24,12L24,12L24,12L24,12z" />
    <path
        android:name="top"
        android:fillColor="#EBEBEB"
        android:pathData="M39,15c0,1.7-6.7,3-15,3S9,16.7,9,15s6.7-3,15-3S39,13.3,39,15z" />
    <path
        android:name="r_ant"
        android:fillColor="#FFFFFF"
        android:pathData="M35,15c-0.1,0-0.3,0-0.4-0.1c-0.5-0.2-0.8-0.8-0.5-1.3l2-5c0.2-0.5,0.8-0.8,1.3-0.5
c0.5,0.2,0.8,0.8,0.5,1.3l-2,5C35.7,14.8,35.3,15,35,15z" />
    <path
        android:name="l_ant"
        android:fillColor="#FFFFFF"
        android:pathData="M13,15c0.1,0,0.3,0,0.4-0.1c0.5-0.2,0.8-0.8,0.5-1.3l-2-5c-0.2-0.5-0.8-0.8-1.3-0.5
c-0.5,0.2-0.8,0.8-0.5,1.3l2,5C12.3,14.8,12.7,15,13,15z" />
    <path
        android:name="smile"
        android:fillColor="#EBEBEB"
        android:pathData="M22,32C22,32,22,32.1,22,32c0,0.9,0.6,1.5,1.4,1.5h1.1c0.8,0,1.5-0.7,1.5-1.5c0,0,0-0.1,0-0.1H22z" />
    <path
        android:name="l_eye"
        android:fillColor="#EBEBEB"
        android:pathData="M16,20c-2.8,0-5,2.2-5,5c0,2.8,2.2,5,5,5c2.8,0,5-2.2,5-5C21,22.2,18.8,20,16,20z" />
    <path
        android:name="r_eye"
        android:fillColor="#EBEBEB"
        android:pathData="M32,20c-2.8,0-5,2.2-5,5c0,2.8,2.2,5,5,5c2.8,0,5-2.2,5-5C37,22.2,34.8,20,32,20z" />
</vector>
+3 −0
Original line number Diff line number Diff line
@@ -95,4 +95,7 @@

    <!-- Advanced settings switch -->
    <java-symbol type="string" name="lock_to_app_toast_no_navbar" />

    <!-- PlatLogo -->
    <java-symbol type="drawable" name="platlogo_cm" />
</resources>
+33 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
    Copyright (C) 2014 The CyanogenMod Project

    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

         http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
    android:width="48dp"
    android:height="48dp"
    android:viewportWidth="48"
    android:viewportHeight="48">

    <group>
        <path
            android:name="torso"
            android:pathData="M35.616,28.128l-4.185-11.17c-0.37-0.966-1.233-1.561-2.11-1.862c-0.638-0.219-1.94-0.47-4.366-0.59h-1.91 c-2.427,0.12-3.729,0.371-4.367,0.59c-0.877,0.301-1.74,0.896-2.11,1.862l-4.185,11.17c-0.496,1.122,0.396,1.59,1.148,1.385 c0.809-0.221,1.518-0.506,2.084-1.866c0.309-0.742,2.818-7.124,2.818-7.124l-1.542,27.45c0,0,0.603,0,2.095,0 c0.967,0,2.209-1.01,2.419-3.358l0.931-12.818h0.709h0.104h0.562h0.241h0.005h0.085h0.005h0.241h0.562h0.104h0.709l0.931,12.818 c0.21,2.348,1.452,3.358,2.419,3.358c1.492,0,2.095,0,2.095,0l-1.542-27.45c0,0,2.509,6.382,2.818,7.124  c0.566,1.36,1.275,1.645,2.084,1.866C35.221,29.718,36.112,29.25,35.616,28.128Z M24,25.331c-1.817,0-3.295-1.478-3.295-3.295  c0-1.817,1.478-3.295,3.295-3.295c1.817,0,3.295,1.478,3.295,3.295C27.295,23.853,25.817,25.331,24,25.331z M26.616,22.036  c0,1.443-1.174,2.616-2.616,2.616c-1.443,0-2.616-1.174-2.616-2.616c0-1.442,1.174-2.616,2.616-2.616  C25.442,19.42,26.616,20.593,26.616,22.036z"
            android:fillColor="#FFFFFF" />
        <path
            android:name="head"
            android:pathData="M29.081,3.012l0.962-2.35c0.096-0.235-0.016-0.503-0.251-0.599c-0.235-0.096-0.503,0.016-0.599,0.251l-0.997,2.435 c-1.1-0.252-2.503-0.348-4.18-0.348v0.006h0V2.4c-0.219,0-0.432,0.002-0.642,0.006h-0.001c-1.396,0.023-2.581,0.124-3.537,0.343 l-0.997-2.435c-0.096-0.235-0.364-0.347-0.599-0.251c-0.235,0.096-0.347,0.364-0.251,0.599l0.962,2.35 c-1.277,0.483-1.955,1.3-1.955,2.612v2.752V9.09v0.784c0,2.411,2.284,3.151,6.377,3.218v0.004h0.254 c0.128,0.001,0.258,0.002,0.389,0.002v-0.002h0v0.002c0.131,0,0.261-0.001,0.389-0.002h0.018c4.242-0.042,6.613-0.764,6.613-3.221  V9.09V8.376V5.624C31.037,4.311,30.358,3.495,29.081,3.012Z M20.407,9.78c-1.16,0-2.1-0.94-2.1-2.1c0-1.16,0.94-2.1,2.1-2.1  c1.16,0,2.1,0.94,2.1,2.1C22.507,8.84,21.567,9.78,20.407,9.78z M24.237,11.303h-0.443c-0.326,0-0.591-0.264-0.591-0.591  c0-0.012,0.003-0.024,0.004-0.036h1.617c0.001,0.012,0.004,0.023,0.004,0.036C24.828,11.039,24.563,11.303,24.237,11.303z M27.625,9.78c-1.16,0-2.1-0.94-2.1-2.1c0-1.16,0.94-2.1,2.1-2.1c1.16,0,2.1,0.94,2.1,2.1C29.724,8.84,28.784,9.78,27.625,9.78z"
            android:fillColor="#FFFFFF" />
    </group>
</vector>
+104 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
     Copyright (C) 2015 The Android Open Source Project
     Copyright (C) 2014-2015 The CyanogenMod Project

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
     You may obtain a copy of the License at

          http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     See the License for the specific language governing permissions and
     limitations under the License.
-->
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
              android:orientation="vertical"
              android:layout_width="match_parent"
              android:layout_height="match_parent"
        >
    <com.android.systemui.egg.CMLand
            android:id="@+id/world"
            android:layout_width="match_parent"
            android:layout_height="match_parent">
    </com.android.systemui.egg.CMLand>
    <FrameLayout
            android:id="@+id/welcome"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:visibility="gone"
            android:background="#a0000000"
            android:clickable="true"
            >
        <FrameLayout
            android:id="@+id/play_button"
            android:layout_width="72dp"
            android:layout_height="72dp"
            android:layout_gravity="center"
            android:clickable="true"
            android:background="@drawable/ripplebg"
            android:focusable="true"
            android:onClick="startButtonPressed"
            >
            <ImageView
                android:id="@+id/play_button_image"
                android:layout_width="48dp"
                android:layout_height="48dp"
                android:scaleType="fitCenter"
                android:layout_gravity="center"
                android:tint="#000000"
                android:src="@drawable/play"
                />
            <TextView
                android:id="@+id/play_button_text"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_gravity="center"
                android:alpha="0"
                android:textSize="40dp"
                android:textColor="#000000"
                />
        </FrameLayout>
    </FrameLayout>
    <LinearLayout
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_gravity="top|center_horizontal"
        android:orientation="horizontal"
        android:gravity="center_vertical"
        android:id="@+id/player_setup"
        >
        <ImageButton
            style="@android:style/Widget.Material.Button.Borderless"
            android:id="@+id/player_minus_button"
            android:layout_width="48dp"
            android:layout_height="48dp"
            android:padding="10dp"
            android:scaleType="centerInside"
            android:onClick="playerMinus"
            android:src="@drawable/minus"
            />
        <LinearLayout
            android:id="@+id/scores"
            android:layout_width="wrap_content"
            android:layout_height="64dp"
            android:padding="12dp"
            android:orientation="horizontal"
            android:clipToPadding="false"
            >
        </LinearLayout>
        <ImageButton
            style="@android:style/Widget.Material.Button.Borderless"
            android:id="@+id/player_plus_button"
            android:layout_width="48dp"
            android:layout_height="48dp"
            android:padding="10dp"
            android:scaleType="centerInside"
            android:onClick="playerPlus"
            android:src="@drawable/plus"
            />
    </LinearLayout>
</FrameLayout>
Loading