Quantcast
Channel: Appcelerator Developer Center Q&A Unanswered Questions 20
Viewing all articles
Browse latest Browse all 8068

I get [WARN] : ActionBarProxy: (main) [276,6033] ActionBar is not enabled Error

$
0
0

Hey,

here is my actionbar code:

...
    var newWin = Ti.UI.createWindow({
        backgroundColor: "red",
        title:"Some Title Here",
        navBarHidden:false,
    modal: true,
    });
 
    newWin.addEventListener("open", function() {
        if (Ti.Platform.osname === "android") {
            if (! newWin.activity) {
                alert("Can't access action bar on a lightweight window.");
            } else {
                actionBar = newWin.activity.actionBar;
                if (actionBar) {
                    actionBar.backgroundColor = "black";
                    actionBar.title = "New Title";
                    actionBar.onHomeIconItemSelected = function() {
                        alert("Home icon clicked!");
                    };
                }
            }
        }
    });
When i get to load this window, I get no alerts, but instead the message that my app has stopped. In the logs (on the titanium-eclipse development kit) i get the message:

[WARN] : ActionBarProxy: (main) [7916,39769] ActionBar is not enabled

Here is some of my tiapp.xml file

<ti:app xmlns:ti="http://ti.appcelerator.org">
    <navbar-hidden>true</navbar-hidden>
        ...
        ...
        <android xmlns:android="http://schemas.android.com/apk/res/android">
            <manifest >
                <application android:theme="@style/Theme.Wibbler"/>
                <uses-sdk android:minSdkVersion="11" android:targetSdkVersion="14"/>
            </manifest>
        </android>
Is there anything else that can cause the actionbar to fail? I have done a Project > Clean... > Clean all projects, and also a fresh install of my app. Is there anything that needs to be done for the ActionBar to work?

Viewing all articles
Browse latest Browse all 8068

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>