Change manifest cancels after build

I made changes to my manifest (adding a new action). I copy and paste the code of another user (this was the first time I set the parent activity). I accidentally built with the wrong code, and this gave me an error regarding resources (which I understand). Then I made changes to the manifest, but every time I build or clean, it returns it to the original version and spits out errors for this. I can't find anything about giving up the code, so I appreciate any help.

       <activity
            android:name="com.willnasby.your_turn.HistoryActivity"
            android:label="History"
            android:parentActivityName="com.willnasby.your_turn.MainActivity" >

            <!-- Parent activity meta-data to support 4.0 and lower -->
            <meta-data
                android:name="android.support.PARENT_ACTIVITY"
                android:value="com.willnasby.your_turn.MainActivity" />
        </activity>

keeps coming back to

        <activity
            android:name="com.example.myfirstapp.DisplayMessageActivity"
            android:label="@string/title_activity_display_message"
            android:parentActivityName="com.example.myfirstapp.MainActivity" >

            <!-- Parent activity meta-data to support 4.0 and lower -->
            <meta-data
                android:name="android.support.PARENT_ACTIVITY"
                android:value="com.example.myfirstapp.MainActivity" />
        </activity>

every time I try to build.

Thank.

EDIT: I read another post about how my versions might not sync with gradle, but I did it and still come back.

+4
3

, , SRC. SRC, .

+16

, ( Android Studio), . , , .

: 1) ( ) . 2) 3) . Android Studio , , .

+1

I assume that you are opening debug / AndroidManifest.xml, try opening main / AndroidManifest.xml, this will come right.

0
source

Source: https://habr.com/ru/post/1568565/


All Articles