0
|
1 |
/*
|
|
2 |
* Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies).
|
|
3 |
* All rights reserved.
|
|
4 |
* This component and the accompanying materials are made available
|
|
5 |
* under the terms of the License "Eclipse Public License v1.0"
|
|
6 |
* which accompanies this distribution, and is available
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
8 |
*
|
|
9 |
* Initial Contributors:
|
|
10 |
* Nokia Corporation - initial contribution.
|
|
11 |
*
|
|
12 |
* Contributors:
|
|
13 |
*
|
|
14 |
* Description:
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
include("../containers/containerLibrary.js")
|
|
20 |
include("../srcgenLibrary.js")
|
|
21 |
|
|
22 |
function AvkonViewReferenceImpl() {
|
|
23 |
}
|
|
24 |
|
|
25 |
AvkonViewReferenceImpl.prototype.propertyChanged = function(instance, property) {
|
|
26 |
if ((property == "tabText") || (property == "tabImage") || (property == "inTabGroup")) {
|
|
27 |
var statusPane = getStatusPane(instance.parent.children);
|
|
28 |
if (statusPane != null) {
|
|
29 |
var naviTabs = findImmediateChildByComponentID(statusPane.children, "com.nokia.sdt.series60.NaviTabs");
|
|
30 |
if (naviTabs != null)
|
|
31 |
naviTabs.forceRedraw(); // force tab group to redraw
|
|
32 |
}
|
|
33 |
}
|
|
34 |
}
|
|
35 |
|
|
36 |
AvkonViewReferenceImpl.prototype.getViewableSize = function(instance, propertyId, laf) {
|
|
37 |
var bounds = laf.getRectangle("navi.content.bounds");
|
|
38 |
return new Point(bounds.width, bounds.height);
|
|
39 |
}
|
|
40 |
|
|
41 |
AvkonViewReferenceImpl.prototype.getAlignmentWeights = function(instance, propertyId, laf) {
|
|
42 |
return new Point(ImageUtils.ALIGN_CENTER, ImageUtils.ALIGN_CENTER_OR_TOP);
|
|
43 |
}
|
|
44 |
|
|
45 |
AvkonViewReferenceImpl.prototype.isScaling = function(instance, propertyId, laf) {
|
|
46 |
return isScalingIcons();
|
|
47 |
}
|
|
48 |
|
|
49 |
AvkonViewReferenceImpl.prototype.isPreservingAspectRatio = function(instance, propertyId, laf) {
|
|
50 |
return true;
|
|
51 |
}
|
|
52 |
|