Fix namespacing

It seems QtQuick2 is more picky about imports inside components in the
same directory (i.e. import "."). We can work around this, however, by
putting it in a namespace.

Makes all the values in enums.h accessible, and generally not error out
when we're importing ".".
This commit is contained in:
Sebastian Kügler 2013-02-14 06:01:29 +01:00
parent 5aed151284
commit 81302acf9d
2 changed files with 7 additions and 7 deletions

View File

@ -40,7 +40,7 @@
import QtQuick 2.0
import "." 0.1
import "." 0.1 as PlasmaComponents
/**
* Defines the content of a piece of the user interface, it's meant to be
@ -62,7 +62,7 @@ Item {
* - PageStatus.Active: the page is the current active page
* - PageStatus.Deactivating: the page is transitioning into becoming inactive
*/
property int status: PageStatus.Inactive
property int status: PlasmaComponents.PageStatus.Inactive
/**
* type:PageStack
@ -73,7 +73,7 @@ Item {
/**
* Sets the orientation for the Page
*/
property int orientationLock: PageOrientation.Automatic
property int orientationLock: PlasmaComponents.PageOrientation.Automatic
/**
* Defines the toolbar contents for the page. If the page stack is set up

View File

@ -41,7 +41,7 @@
import QtQuick 2.0
import "private/TabGroup.js" as Engine
import "." 0.1
import "." 0.1 as PlasmaComponents
/**
* Provides a set of pages for a tab-based interface.
@ -156,7 +156,7 @@ Item {
state = ""
if (priv.incomingPage) {
if (priv.incomingPage.status != undefined) {
priv.incomingPage.status = PageStatus.Active
priv.incomingPage.status = PlasmaComponents.PageStatus.Active
}
priv.incomingPage = null
}
@ -165,7 +165,7 @@ Item {
function outgoingDone() {
if (priv.outgoingPage) {
if (priv.outgoingPage.status != undefined) {
priv.outgoingPage.status = PageStatus.Active
priv.outgoingPage.status = PlasmaComponents.PageStatus.Active
}
priv.outgoingPage.visible = false
priv.outgoingPage = null
@ -245,7 +245,7 @@ Item {
incomingPage = currentTabContainer.children[0]
incomingPage.visible = true
if (incomingPage.status != undefined) {
incomingPage.status = PageStatus.Activating
incomingPage.status = PlasmaComponents.PageStatus.Activating
}
if (currentIndex < newCurrentIndex) {
currentTabContainer.state = "HiddenLeft"