Create a single NS app for cuteness.io, gallery-app and ui-tests-app in apps/

Move all other apps to https://github.com/NativeScript/tns-apps-graveyard
This commit is contained in:
Rossen Hristov
2016-07-05 18:09:57 +03:00
parent c2867e7a1c
commit a18d5e7622
484 changed files with 756 additions and 5501 deletions

View File

@@ -1,2 +0,0 @@
{ "name" : "app-resources",
"main" : "dummy.js" }

View File

@@ -1,23 +0,0 @@
Copyright (c) 2015, Telerik AD
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

View File

@@ -1,2 +0,0 @@
import application = require("application");
application.start({ moduleName: "mainPage" });

View File

@@ -1,56 +0,0 @@
import pagesModule = require("ui/page");
import enums = require("ui/enums");
import absoluteLayoutModule = require("ui/layouts/absolute-layout");
import labelModule = require("ui/label");
import colorModule = require("color");
export function createPage() {
var colors = [
new colorModule.Color("Red"),
new colorModule.Color("LightGreen"),
new colorModule.Color("LightBlue"),
new colorModule.Color("Yellow")
];
var c = 0;
function generateChild(width?: number, height?: number) {
var label = new labelModule.Label();
if (!width) {
width = 80 + Math.round(Math.random() * 40);
}
if (!height) {
height = 80 + Math.round(Math.random() * 40);
}
label.width = width;
label.height = height;
label.text = "L" + c + "(" + label.width + "x" + label.height + ")";
label.style.textAlignment = enums.TextAlignment.center;
label.style.backgroundColor = colors[c % 4];
c++;
return label;
}
var absLayout = new absoluteLayoutModule.AbsoluteLayout();
absLayout.width = 300;
absLayout.height = 300;
absLayout.style.backgroundColor = new colorModule.Color("LightGray");
var x = 0.0;
var y = 0.0;
for (var i = 0; i < 10; i++) {
var child = generateChild(50, 50);
absoluteLayoutModule.AbsoluteLayout.setLeft(child, x);
absoluteLayoutModule.AbsoluteLayout.setTop(child, y);
absLayout.addChild(child);
x += 25;
y += 25;
}
var page = new pagesModule.Page();
page.content = absLayout;
return page;
}
//export var Page = page;

View File

@@ -1,2 +0,0 @@
{ "name" : "absolute-layout-demo",
"main" : "app.js" }

View File

@@ -1,17 +0,0 @@
Page {
background-color: white;
}
ScrollView {
margin: 10;
}
.title {
horizontal-align: center;
font-size: 24;
margin: 6 0;
}
.custom-action-bar {
background-color: lightcoral;
}

View File

@@ -1,6 +0,0 @@
import application = require("application");
// Needed only for build infrastructure
application.cssFile = "app.css";
application.start({ moduleName: "main-page" });

View File

@@ -1,20 +0,0 @@
import observable = require("data/observable");
import frame = require("ui/frame");
export function itemTap(args: observable.EventData) {
frame.topmost().navigate({
moduleName: "pages/" + args.object.get("tag"),
});
}
export function setStyle(args) {
var page = args.object.actionBar.page;
page.css = "ActionBar { color: red; }";
}
export function clearStyle(args) {
var page = args.object.actionBar.page;
page.css = "Page { background-color: red; }";
}

View File

@@ -1,25 +0,0 @@
<?xml version="1.0" encoding="UTF-8" ?>
<Page>
<Page.actionBar>
<ActionBar title="Title" class="custom-action-bar">
<ActionBar.actionItems>
<ActionItem text="set" tap="setStyle"/>
<ActionItem text="clear" tap="clearStyle"/>
</ActionBar.actionItems>
</ActionBar>
</Page.actionBar>
<ScrollView>
<StackLayout>
<Button tap="itemTap" text="action bar hidden" tag="action-bar-hidden" />
<Button tap="itemTap" text="page title and icon" tag="page-title-icon" />
<Button tap="itemTap" text="navigation button" tag="navigation-button" />
<Button tap="itemTap" text="action items icons" tag="action-items-icon" />
<Button tap="itemTap" text="action items text" tag="action-items-text" />
<Button tap="itemTap" text="data binding" tag="data-binding" />
<Button tap="itemTap" text="center view" tag="center-view" />
<Button tap="itemTap" text="center segmented" tag="center-view-segmented" />
<Button tap="itemTap" text="center stack" tag="center-view-stack" />
<Button tap="itemTap" text="all between tags" tag="all-between-tags" />
</StackLayout>
</ScrollView>
</Page>

View File

@@ -1,2 +0,0 @@
{ "name" : "action-bar-demo",
"main" : "app.js" }

View File

@@ -1,9 +0,0 @@
import pages = require("ui/page");
import view = require("ui/core/view");
var toggle = false;
export function toggleTap(args) {
var page = <pages.Page>(<view.View>args.object).page;
page.actionBarHidden = toggle;
toggle = !toggle;
}

View File

@@ -1,8 +0,0 @@
<Page actionBarHidden="true">
<Page.actionBar>
<ActionBar title="Hide Test"/>
</Page.actionBar>
<StackLayout>
<Button text="hide/show" tap="toggleTap" />
</StackLayout>
</Page>

View File

@@ -1,20 +0,0 @@
export function searchTap(args) {
console.log("Search item tapped!");
}
export function cameraTap(args) {
console.log("Camera item tapped!");
}
export function trashTap(args) {
console.log("Trash item tapped!");
}
export function iconTap(args) {
console.log("Icon item tapped!");
}
export function popTap(args) {
console.log("Popup item tapped!");
}

View File

@@ -1,16 +0,0 @@
<Page>
<Page.actionBar>
<ActionBar title="Title">
<ActionBar.actionItems>
<ActionItem tap="searchTap" ios.Position="left" ios.systemIcon="12" android.systemIcon="ic_menu_search"/>
<ActionItem tap="cameraTap" ios.Position="right" ios.systemIcon="15" android.systemIcon="ic_menu_camera"/>
<ActionItem tap="trashTap" ios.Position="right" ios.systemIcon="16" android.systemIcon="ic_menu_delete"/>
<ActionItem tap="iconTap" ios.position="right" icon="~/test-icon.png" />
<ActionItem tap="popTap" ios.position="right" android.position="popup" text="pop"/>
</ActionBar.actionItems>
</ActionBar>
</Page.actionBar>
<StackLayout>
<Button text="button" />
</StackLayout>
</Page>

View File

@@ -1,11 +0,0 @@
export function leftTap(args) {
console.log("Left item tapped!");
}
export function rightTap(args) {
console.log("Right item tapped!");
}
export function popTap(args) {
console.log("Popup item tapped!");
}

View File

@@ -1,14 +0,0 @@
<Page>
<Page.actionBar>
<ActionBar title="Title">
<ActionBar.actionItems>
<ActionItem text="left" tap="leftTap" ios.position="left"/>
<ActionItem text="right" tap="rightTap" ios.position="right"/>
<ActionItem text="pop" tap="popTap" ios.position="right" android.position="popup"/>
</ActionBar.actionItems>
</ActionBar>
</Page.actionBar>
<StackLayout>
<Button text="button" />
</StackLayout>
</Page>

View File

@@ -1,5 +0,0 @@
import observable = require("data/observable");
export function onTapped(args: observable.EventData) {
console.log(`Tapped ${(<any>args.object).text}`);
}

View File

@@ -1,15 +0,0 @@
<Page>
<Page.actionBar>
<ActionBar>
<ActionItem text="i1" tap="onTapped"/>
<Label text="tv" tap="onTapped"/>
<ActionItem text="i2" tap="onTapped"/>
<NavigationButton text="nb" android.systemIcon="ic_menu_back" tap="onTapped"/>
<ActionItem text="i3" tap="onTapped"/>
</ActionBar>
</Page.actionBar>
<StackLayout>
<Label text="page content"/>
</StackLayout>
</Page>

View File

@@ -1,8 +0,0 @@
import observable = require("data/observable");
import pages = require("ui/page");
export function pageLoaded(args) {
var page = <pages.Page>args.object;
var vm = new observable.Observable();
page.bindingContext = vm;
}

View File

@@ -1,18 +0,0 @@
<Page loaded="pageLoaded">
<Page.actionBar>
<ActionBar title="Title">
<ActionBar.titleView>
<SegmentedBar selectedIndex="{{ index }}">
<SegmentedBar.items>
<SegmentedBarItem title="Item 1" />
<SegmentedBarItem title="Item 2" />
<SegmentedBarItem title="Item 3" />
</SegmentedBar.items>
</SegmentedBar>
</ActionBar.titleView>
</ActionBar>
</Page.actionBar>
<StackLayout>
<Button text="{{ index }}" />
</StackLayout>
</Page>

View File

@@ -1,8 +0,0 @@
import observable = require("data/observable");
import pages = require("ui/page");
export function pageLoaded(args) {
var page = <pages.Page>args.object;
var vm = new observable.Observable();
page.bindingContext = vm;
}

View File

@@ -1,16 +0,0 @@
<Page loaded="pageLoaded">
<Page.actionBar>
<ActionBar title="Title">
<ActionBar.titleView>
<StackLayout orientation="horizontal">
<Button text="1st" />
<Button text="2nd" />
<Button text="3rd" />
</StackLayout>
</ActionBar.titleView>
</ActionBar>
</Page.actionBar>
<StackLayout>
<Button text="do nothong" />
</StackLayout>
</Page>

View File

@@ -1,12 +0,0 @@
import observable = require("data/observable");
import pages = require("ui/page");
export function pageLoaded(args) {
var page = <pages.Page>args.object;
var vm = new observable.Observable();
vm.set("centerText", "center text");
vm.set("centerTap", function () {
console.log("Center view tapped!");
});
page.bindingContext = vm;
}

View File

@@ -1,12 +0,0 @@
<Page loaded="pageLoaded">
<Page.actionBar>
<ActionBar title="Title">
<ActionBar.titleView>
<Button text="{{ centerText }}" tap="{{ centerTap }}" />
</ActionBar.titleView>
</ActionBar>
</Page.actionBar>
<StackLayout>
<Button text="do nothing" />
</StackLayout>
</Page>

View File

@@ -1,58 +0,0 @@
import observable = require("data/observable");
import view = require("ui/core/view");
import pages = require("ui/page");
export function pageLoaded(args) {
var page = <pages.Page>args.object;
var vm = new observable.Observable();
vm.set("title", "title");
vm.set("navText", "navText");
vm.set("firstItemText", "txt");
vm.set("secondItemIcon", "res://ic_test");
vm.set("mainIcon", "res://ic_test");
vm.set("navIcon", "res://ic_test");
vm.set("firstItemTap", function () {
console.log("firstItemTap");
});
vm.set("secondItemTap", function () {
console.log("secondItemTap");
});
vm.set("navTap", function () {
console.log("navTap");
});
page.bindingContext = vm;
}
var i = 0;
export function buttonTap(args) {
var page = <pages.Page>(<view.View>args.object).page;
var vm = page.bindingContext;
var icon;
if (i % 3 === 0) {
icon = "res://ic_test";
}
else if (i % 3 === 1) {
icon = "~/action-bar-demo/test-icon.png";
}
else if (i % 3 === 2) {
icon = undefined;
}
vm.set("title", "title " + i);
vm.set("navText", "navText " + i);
vm.set("firstItemText", "txt " + i);
vm.set("secondItemIcon", icon);
vm.set("mainIcon", icon);
vm.set("navIcon", icon);
vm.set("firstItemTap", function () {
var j = i;
console.log("firstItemTap " + j);
});
vm.set("secondItemTap", function () {
var j = i;
console.log("secondItemTap " + j);
});
vm.set("navTap", function () {
var j = i;
console.log("navTap " + j);
});
i++;
}

View File

@@ -1,14 +0,0 @@
<Page loaded="pageLoaded">
<Page.actionBar>
<ActionBar title="{{ title }}" icon="{{ mainIcon }}">
<NavigationButton text="{{ navText }}" icon="{{ navIcon }}" tap="{{ navTap }}"/>
<ActionBar.actionItems>
<ActionItem text="{{ firstItemText }}" tap="{{ firstItemTap }}" ios.position="left"/>
<ActionItem icon="{{ secondItemIcon }}" tap="{{ secondItemTap }}" ios.position="right"/>
</ActionBar.actionItems>
</ActionBar>
</Page.actionBar>
<StackLayout>
<Button text="button" tap="buttonTap"/>
</StackLayout>
</Page>

View File

@@ -1,48 +0,0 @@
import observable = require("data/observable");
import pages = require("ui/page");
import action = require("ui/action-bar");
import view = require("ui/core/view");
var i = 0;
export function buttonTap(args: observable.EventData) {
var page = <pages.Page>(<view.View>args.object).page;
var navBtn = new action.NavigationButton();
navBtn.text = "nav " + i++;
if (i % 3 === 0) {
navBtn.icon = "res://ic_test";
}
else if (i % 3 === 1) {
navBtn.icon = "~/test-icon.png";
}
else if (i % 3 === 2) {
// no icon
}
navBtn.on("tap", navTap);
page.actionBar.navigationButton = navBtn;
}
var j = 0;
export function visibilityTap(args: observable.EventData) {
var page = <pages.Page>(<view.View>args.object).page;
if (page.actionBar.android) {
if (j % 3 === 0) {
page.actionBar.android.iconVisibility = "always";
}
else if (j % 3 === 1) {
page.actionBar.android.iconVisibility = "never";
}
else if (j % 3 === 2) {
page.actionBar.android.iconVisibility = "auto";
}
j++;
console.log("Visibility changed to: " + page.actionBar.android.iconVisibility);
}
}
export function navTap(args: observable.EventData) {
console.log("(Android only) Navigation button tapped");
}

View File

@@ -1,12 +0,0 @@
<Page>
<Page.actionBar>
<ActionBar title="Navigation Button">
<NavigationButton text="ios back" android.systemIcon = "ic_menu_back" tap="navTap"/>
</ActionBar>
</Page.actionBar>
<StackLayout>
<Button text="button" tap="buttonTap"/>
<Button text="change icon visibility" tap="visibilityTap"/>
</StackLayout>
</Page>

View File

@@ -1,40 +0,0 @@
import observable = require("data/observable");
import pages = require("ui/page");
import view = require("ui/core/view");
var i = 0;
export function buttonTap(args: observable.EventData) {
var page = <pages.Page>(<view.View>args.object).page;
page.actionBar.title = "Title changed " + i++;
if (page.actionBar.android) {
if (i % 3 === 0) {
page.actionBar.android.icon = "res://ic_test";
}
else if (i % 3 === 1) {
page.actionBar.android.icon = "~/test-icon.png";
}
else if (i % 3 === 2) {
page.actionBar.android.icon = undefined;
}
}
}
var j = 0;
export function visibilityTap(args: observable.EventData) {
var page = <pages.Page>(<view.View>args.object).page;
if (page.actionBar.android) {
if (j % 3 === 0) {
page.actionBar.android.iconVisibility = "always";
}
else if (j % 3 === 1) {
page.actionBar.android.iconVisibility = "never";
}
else if (j % 3 === 2) {
page.actionBar.android.iconVisibility = "auto";
}
j++;
console.log("Visibility changed to: " + page.actionBar.android.iconVisibility);
}
}

View File

@@ -1,9 +0,0 @@
<Page>
<Page.actionBar>
<ActionBar title="Page Title" icon="res://ic_test"/>
</Page.actionBar>
<StackLayout>
<Button text="button" tap="buttonTap"/>
<Button text="change main icon visibility" tap="visibilityTap"/>
</StackLayout>
</Page>

View File

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

View File

@@ -1,3 +0,0 @@
page {
/* CSS styles */
}

View File

@@ -1,7 +0,0 @@
import application = require("application");
import trace = require("trace");
trace.enable();
trace.setCategories(trace.categories.concat(trace.categories.Animation));
application.start({ moduleName: "main-page" });

View File

Binary file not shown.

Before

Width:  |  Height:  |  Size: 311 B

View File

@@ -1,170 +0,0 @@
import observable = require("data/observable");
import pages = require("ui/page");
import buttonModule = require("ui/button");
import abs = require("ui/layouts/absolute-layout");
import animationModule = require("ui/animation");
import colorModule = require("color");
import model = require("./model");
import enums = require("ui/enums");
import frame = require("ui/frame");
var vm = new model.ViewModel();
var page: pages.Page;
var panel: abs.AbsoluteLayout;
var button1: buttonModule.Button;
var button2: buttonModule.Button;
var button3: buttonModule.Button;
var buttonAnimation: animationModule.Animation;
var panelAnimation: animationModule.Animation;
export function pageLoaded(args: observable.EventData) {
page = <pages.Page>args.object;
page.bindingContext = vm;
panel = page.getViewById<abs.AbsoluteLayout>("panel1");
button1 = page.getViewById<buttonModule.Button>("button1");
button2 = page.getViewById<buttonModule.Button>("button2");
button3 = page.getViewById<buttonModule.Button>("button3");
}
export function onSlideOut(args: observable.EventData) {
console.log("onSlideOut");
var curve = enums.AnimationCurve.easeOut;
var buttonAnimations = [
{ target: button1, translate: { x: -240, y: 0 }, scale: { x: 0.5, y: 0.5 }, opacity: 0, duration: vm.duration, delay: 0, iterations: vm.iterations, curve: curve },
{ target: button2, translate: { x: -240, y: 0 }, scale: { x: 0.5, y: 0.5 }, opacity: 0, duration: vm.duration, delay: vm.duration, iterations: vm.iterations, curve: curve },
{ target: button3, translate: { x: -240, y: 0 }, scale: { x: 0.5, y: 0.5 }, opacity: 0, duration: vm.duration, delay: vm.duration * 2, iterations: vm.iterations, curve: curve },
]
buttonAnimation = new animationModule.Animation(buttonAnimations, vm.playSequentially);
panelAnimation = panel.createAnimation({ opacity: 0, scale: { x: 0.5, y: 0.5 }, rotate: -360, backgroundColor: new colorModule.Color("red"), duration: vm.duration, iterations: vm.iterations, curve: enums.AnimationCurve.easeInOut });
buttonAnimation.play()
.then(() => panelAnimation.play())
.catch((e) => console.log(e.message));
}
export function onSlideIn(args: observable.EventData) {
console.log("onSlideIn");
var curve = enums.AnimationCurve.easeIn;
panelAnimation = panel.createAnimation({ opacity: 1, scale: { x: 1, y: 1 }, rotate: 0, backgroundColor: new colorModule.Color("yellow"), duration: vm.duration, iterations: vm.iterations, curve: enums.AnimationCurve.easeInOut });
var buttonAnimations = [
{ target: button3, translate: { x: 0, y: 0 }, scale: { x: 1, y: 1 }, opacity: 1, duration: vm.duration, delay: 0, iterations: vm.iterations, curve: curve },
{ target: button2, translate: { x: 0, y: 0 }, scale: { x: 1, y: 1 }, opacity: 1, duration: vm.duration, delay: vm.duration, iterations: vm.iterations, curve: curve },
{ target: button1, translate: { x: 0, y: 0 }, scale: { x: 1, y: 1 }, opacity: 1, duration: vm.duration, delay: vm.duration * 2, iterations: vm.iterations, curve: curve },
]
buttonAnimation = new animationModule.Animation(buttonAnimations, vm.playSequentially);
panelAnimation.play()
.then(() => buttonAnimation.play())
.catch((e) => console.log(e.message));
}
export function onCancel(args: observable.EventData) {
console.log("onCancel");
if (panelAnimation.isPlaying) {
panelAnimation.cancel();
}
if (buttonAnimation.isPlaying) {
buttonAnimation.cancel();
}
}
export function onTap(args: observable.EventData) {
console.log((<any>args.object).text);
}
export function onSingle(args: observable.EventData) {
console.log("onSingle");
button1.animate({
opacity: 0.75,
backgroundColor: new colorModule.Color("Red"),
translate: { x: 100, y: 100 },
scale: { x: 2, y: 2 },
rotate: 180,
duration: vm.duration,
delay: 0,
iterations: vm.iterations,
curve: enums.AnimationCurve.linear,
})
.then(() => console.log("Animation finished"))
.catch((e) => console.log(e.message));
}
export function onSequence(args: observable.EventData) {
console.log("onSequence");
button3.animate({
translate: { x: 80, y: -40 },
scale: { x: 0.9, y: 0.3 },
rotate: 25,
duration: 1000
})
.then(() => button3.animate({
translate: { x: 0, y: -80 },
scale: { x: 0.5, y: 0.5 },
rotate: -25,
duration: 1000
}))
.then(() => button3.animate({
translate: { x: -80, y: -40 },
scale: { x: 0.5, y: 0.9 },
rotate: 45,
duration: 1000
}))
.then(() => button3.animate({
translate: { x: 0, y: 0 },
scale: { x: 1, y: 1 },
rotate: 0,
duration: 1000
}))
.then(() => console.log("Animation finished"))
.catch((e) => console.log(e.message));
}
export function onInterrupted(args: observable.EventData) {
console.log("onInterrupt");
setTimeout(() => {
button3.animate({
translate: { x: 80, y: -40 },
scale: { x: 0.9, y: 0.3 },
rotate: 25,
duration: 1000
});
}, 700 * 0);
setTimeout(function() {
button3.animate({
translate: { x: 0, y: -80 },
scale: { x: 0.5, y: 0.5 },
rotate: -25,
duration: 1000
})
}, 700 * 1);
setTimeout(function() {
button3.animate({
translate: { x: -80, y: -40 },
scale: { x: 0.5, y: 0.9 },
rotate: 45,
duration: 1000
})
}, 700 * 2);
setTimeout(function() {
button3.animate({
translate: { x: 0, y: 0 },
scale: { x: 1, y: 1 },
rotate: 0,
duration: 1000
})
}, 700 * 3);
}
export function onOpacity(args: observable.EventData) {
frame.topmost().navigate("./opacity");
}

View File

@@ -1,36 +0,0 @@
<Page xmlns="http://schemas.nativescript.org/tns.xsd" loaded="pageLoaded" id="mainPage">
<StackLayout orientation="vertical">
<StackLayout orientation="vertical" backgroundColor="LightGray" paddingTop="5" paddingBottom="5">
<Label text="{{ duration, 'Duration: ' + duration + ' ms' }}" width="180" />
<Slider minValue="0" maxValue="10000" value="{{ duration }}" margin="0 15" />
<Label text="{{ iterations, 'Iterations: ' + iterations + ' times' }}" width="180" />
<Slider minValue="0" maxValue="10" value="{{ iterations }}" margin="0 15" />
<StackLayout orientation="horizontal" horizontalAlignment="center">
<Label text="Play Sequentially?"/>
<Switch marginLeft="10" checked="{{ playSequentially }}"/>
</StackLayout>
<StackLayout orientation="horizontal" marginTop="5" marginBottom="5" horizontalAlignment="center" paddingLeft="5" paddingRight="5">
<Button text="Out" tap="onSlideOut" width="40" marginLeft="5" marginRight="5" />
<Button text="In" tap="onSlideIn" width="40" marginLeft="5" marginRight="5" />
<Button text="Single" tap="onSingle" width="70" marginLeft="5" marginRight="5" />
<Button text="Cancel" tap="onCancel" width="70" marginLeft="5" marginRight="5" />
<Button text="Opacity" tap="onOpacity" width="70" marginLeft="5" marginRight="5" />
</StackLayout>
<StackLayout orientation="horizontal" marginTop="5" marginBottom="5" horizontalAlignment="center" paddingLeft="5" paddingRight="5">>
<Button text="Sequence" width="80" marginLeft="5" marginRight="5" tap="onSequence" />
<Button text="Interrupted" width="80" marginLeft="5" marginRight="5" tap="onInterrupted" />
</StackLayout>
</StackLayout>
<AbsoluteLayout id="panel1" backgroundColor="Yellow" width="300" height="190" clipToBounds="true" marginTop="10">
<Button id="button1" text="Button 1" backgroundColor="White" width="180" height="50" left="60" top="10" tap="onTap" borderWidth="1" borderColor="red" />
<Button id="button2" text="Button 2" backgroundColor="White" width="180" height="50" left="60" top="70" tap="onTap" borderWidth="1" borderColor="red" />
<Button id="button3" text="Button 3" backgroundColor="White" width="180" height="50" left="60" top="130" tap="onTap" borderWidth="1" borderColor="red" />
</AbsoluteLayout>
</StackLayout>
</Page>

View File

@@ -1,37 +0,0 @@
import observable = require("data/observable");
export class ViewModel extends observable.Observable {
constructor() {
super();
this._duration = 3000;
this._iterations = 1;
}
private _playSequentially: boolean;
get playSequentially(): boolean {
return this._playSequentially;
}
set playSequentially(value: boolean) {
this._playSequentially = value;
this.notify({ object: this, eventName: observable.Observable.propertyChangeEvent, propertyName: "playSequentially", value: value });
}
private _duration: number;
get duration(): number {
return this._duration;
}
set duration(value: number) {
this._duration = value;
this.notify({ object: this, eventName: observable.Observable.propertyChangeEvent, propertyName: "duration", value: value });
}
private _iterations: number;
get iterations(): number {
return this._iterations;
}
set iterations(value: number) {
this._iterations = value;
this.notify({ object: this, eventName: observable.Observable.propertyChangeEvent, propertyName: "iterations", value: value });
}
}

View File

@@ -1,27 +0,0 @@
.complex {
width: 45;
height: 45;
margin: 1;
background-image: url('~/bkg.png');
background-repeat:repeat-x;
background-position: 20% 80%;
background-color: lightyellow;
background-size: 25% 50%;
border-radius: 20;
border-width: 4;
border-color: red;
}
.simple {
width: 45;
height: 45;
margin: 1;
border-radius: 20;
background-color: lightgreen;
}
.none {
width: 45;
height: 45;
margin: 1;
}

View File

@@ -1,51 +0,0 @@
import observable = require("data/observable");
import pages = require("ui/page");
import view = require("ui/core/view");
import animationModule = require("ui/animation");
import slider = require("ui/slider");
import wrapLayout = require("ui/layouts/wrap-layout");
var page: pages.Page;
var opacitySlider: slider.Slider;
var container: wrapLayout.WrapLayout;
export function pageLoaded(args: observable.EventData) {
page = <pages.Page>args.object;
opacitySlider = page.getViewById<slider.Slider>("opacitySlider");
container = page.getViewById<wrapLayout.WrapLayout>("container");
}
export function onSetOpacity(args: observable.EventData) {
var newOpacity = opacitySlider.value / 100;
container._eachChildView((view: view.View) => {
//if (view.android) {
// view.android.setLayerType(android.view.View.LAYER_TYPE_HARDWARE, null);
//}
view.opacity = newOpacity;
return true;
});
}
var animationSet: animationModule.Animation;
export function onAnimateOpacity(args: observable.EventData) {
var newOpacity = opacitySlider.value / 100;
var animationDefinitions = new Array<animationModule.AnimationDefinition>();
container._eachChildView((view: view.View) => {
//if (view.android) {
// view.android.setLayerType(android.view.View.LAYER_TYPE_HARDWARE, null);
//}
animationDefinitions.push({
target: view,
opacity: newOpacity,
duration: 5000
});
return true;
});
animationSet = new animationModule.Animation(animationDefinitions);
animationSet.play();
}
export function onReset(args: observable.EventData) {
animationSet.cancel();
}

View File

@@ -1,35 +0,0 @@
<Page xmlns="http://schemas.nativescript.org/tns.xsd" loaded="pageLoaded" id="opacityPage">
<StackLayout orientation="vertical">
<StackLayout orientation="vertical">
<Label text="opacity" width="180" />
<Slider id="opacitySlider" minValue="0" maxValue="100" width="180" />
<Button text="Set" tap="onSetOpacity"/>
<Button text="Animate" tap="onAnimateOpacity"/>
<Button text="Reset" tap="onReset"/>
</StackLayout>
<WrapLayout orientation="horizontal" id="container">
<StackLayout class="complex"/>
<Button text="Button" class="complex"/>
<Label text="Label" class="complex"/>
<Image src="~/test-icon.png" class="complex"/>
<TextField text="TextField" class="complex"/>
<TextView text="TextView" class="complex"/>
<StackLayout class="simple"/>
<Button text="Button" class="simple"/>
<Label text="Label" class="simple"/>
<Image src="~/test-icon.png" class="simple"/>
<TextField text="TextField" class="simple"/>
<TextView text="TextView" class="simple"/>
<StackLayout class="none"/>
<Button text="Button" class="none"/>
<Label text="Label" class="none"/>
<Image src="~/test-icon.png" class="none"/>
<TextField text="TextField" class="none"/>
<TextView text="TextView" class="none"/>
</WrapLayout>
</StackLayout>
</Page>

View File

@@ -1,2 +0,0 @@
{ "name" : "animations",
"main" : "app.js" }

View File

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

View File

@@ -0,0 +1,41 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="__PACKAGE__"
android:versionCode="1"
android:versionName="1.0">
<supports-screens
android:smallScreens="true"
android:normalScreens="true"
android:largeScreens="true"
android:xlargeScreens="true"/>
<uses-sdk
android:minSdkVersion="17"
android:targetSdkVersion="__APILEVEL__"/>
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<application
android:name="com.tns.NativeScriptApplication"
android:allowBackup="true"
android:icon="@drawable/icon"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name="com.tns.NativeScriptActivity"
android:label="@string/title_activity_kimera"
android:configChanges="keyboardHidden|orientation|screenSize">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name="com.tns.ErrorReportActivity"/>
</application>
</manifest>

View File

@@ -0,0 +1,16 @@
// Add your native dependencies here:
// Uncomment to add recyclerview-v7 dependency
//dependencies {
// compile 'com.android.support:recyclerview-v7:+'
//}
android {
defaultConfig {
generatedDensities = []
applicationId = "org.nativescript.apps"
}
aaptOptions {
additionalParameters "--no-version-vectors"
}
}

View File

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

View File

Before

Width:  |  Height:  |  Size: 6.0 KiB

After

Width:  |  Height:  |  Size: 6.0 KiB

View File

Before

Width:  |  Height:  |  Size: 7.4 KiB

After

Width:  |  Height:  |  Size: 7.4 KiB

View File

Before

Width:  |  Height:  |  Size: 26 KiB

After

Width:  |  Height:  |  Size: 26 KiB

View File

@@ -0,0 +1,128 @@
{
"images" : [
{
"size" : "29x29",
"idiom" : "iphone",
"filename" : "icon-29.png",
"scale" : "1x"
},
{
"size" : "29x29",
"idiom" : "iphone",
"filename" : "icon-29@2x.png",
"scale" : "2x"
},
{
"size" : "29x29",
"idiom" : "iphone",
"filename" : "icon-29@3x.png",
"scale" : "3x"
},
{
"size" : "40x40",
"idiom" : "iphone",
"filename" : "icon-40@2x.png",
"scale" : "2x"
},
{
"size" : "40x40",
"idiom" : "iphone",
"filename" : "icon-40@3x.png",
"scale" : "3x"
},
{
"size" : "57x57",
"idiom" : "iphone",
"filename" : "icon-57.png",
"scale" : "1x"
},
{
"size" : "57x57",
"idiom" : "iphone",
"filename" : "icon-57@2x.png",
"scale" : "2x"
},
{
"size" : "60x60",
"idiom" : "iphone",
"filename" : "icon-60@2x.png",
"scale" : "2x"
},
{
"size" : "60x60",
"idiom" : "iphone",
"filename" : "icon-60@3x.png",
"scale" : "3x"
},
{
"size" : "29x29",
"idiom" : "ipad",
"filename" : "icon-29.png",
"scale" : "1x"
},
{
"size" : "29x29",
"idiom" : "ipad",
"filename" : "icon-29@2x.png",
"scale" : "2x"
},
{
"size" : "40x40",
"idiom" : "ipad",
"filename" : "icon-40.png",
"scale" : "1x"
},
{
"size" : "40x40",
"idiom" : "ipad",
"filename" : "icon-40@2x.png",
"scale" : "2x"
},
{
"size" : "50x50",
"idiom" : "ipad",
"filename" : "icon-50.png",
"scale" : "1x"
},
{
"size" : "50x50",
"idiom" : "ipad",
"filename" : "icon-50@2x.png",
"scale" : "2x"
},
{
"size" : "72x72",
"idiom" : "ipad",
"filename" : "icon-72.png",
"scale" : "1x"
},
{
"size" : "72x72",
"idiom" : "ipad",
"filename" : "icon-72@2x.png",
"scale" : "2x"
},
{
"size" : "76x76",
"idiom" : "ipad",
"filename" : "icon-76.png",
"scale" : "1x"
},
{
"size" : "76x76",
"idiom" : "ipad",
"filename" : "icon-76@2x.png",
"scale" : "2x"
},
{
"size" : "83.5x83.5",
"idiom" : "ipad",
"filename" : "icon-83.5@2x.png",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

View File

Before

Width:  |  Height:  |  Size: 4.8 KiB

After

Width:  |  Height:  |  Size: 4.8 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.3 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.2 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 41 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.8 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.7 KiB

View File

@@ -0,0 +1,6 @@
{
"info" : {
"version" : 1,
"author" : "xcode"
}
}

View File

@@ -0,0 +1,158 @@
{
"images" : [
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "736h",
"filename" : "Default-736h@3x.png",
"minimum-system-version" : "8.0",
"orientation" : "portrait",
"scale" : "3x"
},
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "736h",
"filename" : "Default-Landscape@3x.png",
"minimum-system-version" : "8.0",
"orientation" : "landscape",
"scale" : "3x"
},
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "667h",
"filename" : "Default-667h@2x.png",
"minimum-system-version" : "8.0",
"orientation" : "portrait",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"filename" : "Default@2x.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "retina4",
"filename" : "Default-568h@2x.png",
"minimum-system-version" : "7.0",
"orientation" : "portrait",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"filename" : "Default-Portrait.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"filename" : "Default-Landscape.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"filename" : "Default-Portrait@2x.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"filename" : "Default-Landscape@2x.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"filename" : "Default.png",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"filename" : "Default@2x.png",
"extent" : "full-screen",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"filename" : "Default-568h@2x.png",
"extent" : "full-screen",
"subtype" : "retina4",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"filename" : "Default-Portrait.png",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"filename" : "Default-Landscape.png",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"filename" : "Default-Portrait@2x.png",
"extent" : "full-screen",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"filename" : "Default-Landscape@2x.png",
"extent" : "full-screen",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 112 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 180 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 187 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 198 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 182 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"filename" : "LaunchScreen-AspectFill.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "LaunchScreen-AspectFill@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"filename" : "LaunchScreen-Center.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "LaunchScreen-Center@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 65 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 202 KiB

View File

@@ -0,0 +1,47 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleDisplayName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1.0</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIRequiresFullScreen</key>
<true/>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
</dict>
</plist>

View File

@@ -0,0 +1,49 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10116" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" initialViewController="01J-lp-oVM">
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="EHf-IW-A2E">
<objects>
<viewController id="01J-lp-oVM" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="Llm-lL-Icb"/>
<viewControllerLayoutGuide type="bottom" id="xb3-aO-Qok"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3">
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<imageView userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="LaunchScreen.AspectFill" translatesAutoresizingMaskIntoConstraints="NO" id="wtH-rr-YfP">
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
</imageView>
<imageView userInteractionEnabled="NO" contentMode="center" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="LaunchScreen.Center" translatesAutoresizingMaskIntoConstraints="NO" id="s1z-aa-wYv">
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="xb3-aO-Qok" firstAttribute="top" secondItem="wtH-rr-YfP" secondAttribute="bottom" id="5FO-pR-qKb"/>
<constraint firstItem="wtH-rr-YfP" firstAttribute="top" secondItem="Ze5-6b-2t3" secondAttribute="top" id="Awn-b8-xf1"/>
<constraint firstItem="s1z-aa-wYv" firstAttribute="top" secondItem="Ze5-6b-2t3" secondAttribute="top" id="CiP-yX-1sg"/>
<constraint firstAttribute="trailing" secondItem="wtH-rr-YfP" secondAttribute="trailing" id="RXg-rW-UK8"/>
<constraint firstItem="s1z-aa-wYv" firstAttribute="leading" secondItem="Ze5-6b-2t3" secondAttribute="leading" id="agC-wa-3bd"/>
<constraint firstItem="wtH-rr-YfP" firstAttribute="leading" secondItem="Ze5-6b-2t3" secondAttribute="leading" id="cch-8E-tYu"/>
<constraint firstItem="xb3-aO-Qok" firstAttribute="top" secondItem="s1z-aa-wYv" secondAttribute="bottom" id="fNc-Ro-KaG"/>
<constraint firstAttribute="trailing" secondItem="s1z-aa-wYv" secondAttribute="trailing" id="qoI-OC-Zk7"/>
</constraints>
</view>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="510" y="238"/>
</scene>
</scenes>
<resources>
<image name="LaunchScreen.AspectFill" width="768" height="1024"/>
<image name="LaunchScreen.Center" width="40" height="40"/>
</resources>
</document>

View File

@@ -0,0 +1,5 @@
// You can add custom settings here
// for example you can uncomment the following line to force distribution code signing
// CODE_SIGN_IDENTITY = iPhone Distribution
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;

View File

@@ -6,4 +6,4 @@ fps.addCallback(function (fps, minFps) {
fps.start();
// Start the application
application.start({ moduleName: "main-page" });
application.start({ moduleName: "cuteness.io/main-page" });

View File

@@ -22,7 +22,7 @@ export function pageLoaded(args: ObservableEventData) {
export function listViewItemTap(args: ListViewItemEventData) {
// Navigate to the details page with context set to the data item for specified index
topmostFrame().navigate({
moduleName: "./details-page",
moduleName: "cuteness.io/details-page",
context: appViewModel.redditItems.getItem(args.index)
});
}

View File

@@ -20,7 +20,7 @@
<TabViewItem title="About">
<TabViewItem.view>
<StackLayout>
<Image margin="10" src="~/res/telerik-logo.png" />
<Image margin="10" src="~/cuteness.io/res/telerik-logo.png" />
<Label margin="10" textWrap="true" text="{{ aboutText }}" />
</StackLayout>
</TabViewItem.view>

View File

@@ -7,8 +7,8 @@ import {Data as RedditData} from "./reddit-model";
import {RedditViewModel} from "./reddit-item-view-model";
var aboutText = "Cuteness is a proof of concept app demonstrating the Telerik's NativeScript for writing native mobile applications using JavaScript.";
export var defaultThumbnailImageSource = imageSourceFromFile("~/res/reddit-logo.png");
export var defaultNoThumbnailImageSource = imageSourceFromFile("~/res/no-image.png");
export var defaultThumbnailImageSource = imageSourceFromFile("~/cuteness.io/res/reddit-logo.png");
export var defaultNoThumbnailImageSource = imageSourceFromFile("~/cuteness.io/res/no-image.png");
var redditUrl = "http://www.reddit.com/r/aww.json?limit=";
var after: string;

View File

@@ -4,8 +4,8 @@ import {ImageSource, fromFile as imageSourceFromFile, fromUrl as imageSourceFrom
import {ItemData} from "./reddit-model";
import {defaultThumbnailImageSource, defaultNoThumbnailImageSource, cache} from "./reddit-app-view-model";
var firstThumbnailImageSource = imageSourceFromFile("~/res/first-image.png");
var defaultImageSource = imageSourceFromFile("~/res/reddit-logo-transparent.png");
var firstThumbnailImageSource = imageSourceFromFile("~/cuteness.io/res/first-image.png");
var defaultImageSource = imageSourceFromFile("~/cuteness.io/res/reddit-logo-transparent.png");
var ISLOADING = "isLoading";
var THUMBNAIL_IMAGE = "thumbnailImage";

View File

Before

Width:  |  Height:  |  Size: 990 B

After

Width:  |  Height:  |  Size: 990 B

View File

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

View File

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 30 KiB

Some files were not shown because too many files have changed in this diff Show More