<span id="Label3"></p><p><p>The answer in 1.stackoverflow is this, and it's a common situation:</p></p><p><p></p></p><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; color:rgb(34,34,34); font-family:‘Helvetica Neue‘,Helvetica,Arial,sans-serif; line-height:19.5px"><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; color:rgb(34,34,34); font-family:‘Helvetica Neue‘,Helvetica,Arial,sans-serif; line-height:19.5px">AppCompat is now + strict on what it expect in theme window flags, more closely matching what's would get from the FR Amework.</p></p><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; color:rgb(34,34,34); font-family:‘Helvetica Neue‘,Helvetica,Arial,sans-serif; line-height:19.5px"><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; Color:rgb (34,34,34); Font-family: ' Helvetica Neue ', helvetica,arial,sans-serif; line-height:19.5px ">the main reason behind this was to Support appcompatdialogs which we were also added in this Release. They make heavy use of The <code style="margin:0px; padding:1px 5px; border:0px; font-size:13px; font-family:consolas,menlo,monaco, ' Lucida Console ', ' liberation Mono ', ' Dejavu Sans mono ', ' bitstream Vera Sans mono ', ' Courier New ', monospace,sans-serif; white-space:pre-wrap; Background-color:rgb (238,238,238) ">windownotitle </code> flag, which AppCompat previously didn ' t pay much Attention To. </p></p><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; color:rgb(34,34,34); font-family:‘Helvetica Neue‘,Helvetica,Arial,sans-serif; line-height:19.5px"><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; color:rgb(34,34,34); font-family:‘Helvetica Neue‘,Helvetica,Arial,sans-serif; line-height:19.5px">So-to-fix your issue you have the following options:</p></p><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; color:rgb(34,34,34); font-family:‘Helvetica Neue‘,Helvetica,Arial,sans-serif; line-height:19.5px"><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; color:rgb(34,34,34); font-family:‘Helvetica Neue‘,Helvetica,Arial,sans-serif; line-height:19.5px">The easy-to-just use as <code style="margin:0px; padding:1px 5px; border:0px; font-size:13px; font-family:Consolas,Menlo,Monaco,‘Lucida Console‘,‘Liberation Mono‘,‘DejaVu Sans Mono‘,‘Bitstream Vera Sans Mono‘,‘Courier New‘,monospace,sans-serif; white-space:pre-wrap; background-color:rgb(238,238,238)">Theme.AppCompat.NoActionBar</code> your parent Theme. This'll always does the right thing.</p></p><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; color:rgb(34,34,34); font-family:‘Helvetica Neue‘,Helvetica,Arial,sans-serif; line-height:19.5px"><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; Color:rgb (34,34,34); Font-family: ' Helvetica Neue ', helvetica,arial,sans-serif; line-height:19.5px ">if You can ' t do this though (maybe you need to the support Action Bar and no action bar), you should do th E following: </p></p><pre style="margin-top:0px; margin-bottom:1em; padding:5px; border:0px; font-size:13px; overflow:auto; width:auto; max-height:600px; font-family:Consolas,Menlo,Monaco,‘Lucida Console‘,‘Liberation Mono‘,‘DejaVu Sans Mono‘,‘Bitstream Vera Sans Mono‘,‘Courier New‘,monospace,sans-serif; word-wrap:normal; color:rgb(34,34,34); background-color:rgb(238,238,238)"><pre style="margin-top:0px; margin-bottom:1em; padding:5px; border:0px; font-size:13px; overflow:auto; width:auto; max-height:600px; font-family:consolas,menlo,monaco, ' Lucida Console ', ' liberation Mono ', ' Dejavu Sans mono ', ' bitstream Vera Sans mono ', ' Courier New ', monospace,sans-serif; word-wrap:normal; Color:rgb (34,34,34); Background-color:rgb (238,238,238) "><code style=" margin:0px; padding:0px; border:0px; font-family:consolas,menlo,monaco, ' Lucida Console ', ' liberation Mono ', ' Dejavu Sans mono ', ' bitstream Vera Sans mono ', ' Courier New ', monospace,sans-serif; White-space:inherit "><style name=" MyTheme "parent=" theme.appcompat "> ... </style><style name=" Mytheme.noactionbar "> <!--Both of these is needed-to <item name=" windowactionbar ">FALSE</ITEM&G T <item name= "windownotitle" >true</item></style> </code> </pre></pre><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; color:rgb(34,34,34); font-family:‘Helvetica Neue‘,Helvetica,Arial,sans-serif; line-height:19.5px"><p style="margin-top:0px; margin-bottom:1em; padding-top:0px; padding-bottom:0px; border:0px; font-size:15px; clear:both; color:rgb(34,34,34); font-family:‘Helvetica Neue‘,Helvetica,Arial,sans-serif; line-height:19.5px">You should is back on track now.</p></p>2. also my situation:<p><p>In the OnCreate () method, The Super method is called and then the Setcontentview () method is called, and the error occurs if the order is Wrong.</p></p><p><p><br></p></p><p><p>AppCompat does the current theme features</p></p></span>
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service