aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorzefanja <zefanja@freenet.de>2014-04-10 19:52:20 +0700
committerzefanja <zefanja@freenet.de>2014-04-10 19:52:20 +0700
commit3fa41148fe9ac2ae203eb8034d20f2f61b5e040b (patch)
treef3f51f1cdcbbd7e41aba2e2514cc3b52c8be2928
parentfa87a43e100b3b1c3da1bb611de1969f7ed2391f (diff)
downloadbiblez-ng-3fa41148fe9ac2ae203eb8034d20f2f61b5e040b.tar.gz
* fixed minor issues
* fixed history menu rendering * updated submodules
m---------enyo0
m---------lib/layout0
m---------lib/onyx0
-rw-r--r--source/bcSelector.js3
-rw-r--r--source/main.js18
5 files changed, 9 insertions, 12 deletions
diff --git a/enyo b/enyo
-Subproject 8f1c9471a71cf45d57dcfc84b322c62f8379779
+Subproject 0f57e7f3d367fd09c3d2856bcdb248bb1cdaaff
diff --git a/lib/layout b/lib/layout
-Subproject 9b34424ebf03e87bea1d9bcc6f9bddf4c56d6e7
+Subproject 8d9b34a3cd3d5de5c4fee7121af216239e37b12
diff --git a/lib/onyx b/lib/onyx
-Subproject 02113f80c9379d68a0e826d378efd5fa480b219
+Subproject b20c5ff404b505a2285cf9dba1a1860b580f191
diff --git a/source/bcSelector.js b/source/bcSelector.js
index 6b28ee6..4659687 100644
--- a/source/bcSelector.js
+++ b/source/bcSelector.js
@@ -16,6 +16,9 @@ enyo.kind({
{kind: "onyx.IconButton", src: "assets/back.png", ontap: "doBack"},
{content: $L("Books")}
]},
+ /*{kind: "enyo.GridList", name: "bookList", onSetupItem: "setBookItems", itemFluidWidth: true, itemHeight: 44, itemMinWidth: 44, itemSpacing: 6, components: [
+ {name: "bookItem", kind: "onyx.Button", classes: "bc-item", ontap: "handleBook"}
+ ]} */
{kind: "enyo.Scroller", fit: true, touch: true, components: [
{name: "bookRepeater", kind: "Repeater", count: 0, onSetupItem: "setBookItems", components: [
{name: "bookItem", kind: "onyx.Button", classes: "bc-item", ontap: "handleBook"}
diff --git a/source/main.js b/source/main.js
index bb5b9b8..f800e0e 100644
--- a/source/main.js
+++ b/source/main.js
@@ -39,7 +39,7 @@ enyo.kind({
{classes: "toolbar-spinner", name: "tbSpinner", showing: false},
{name: "actionSelector", kind: "onyx.MenuDecorator", onSelect: "actionSelected", components: [
{kind: "onyx.IconButton", src: "assets/menu.png"},
- {kind: "onyx.Menu", name: "actionMenu", maxHeight: "300", style: "width: 200px;", components: [
+ {kind: "onyx.Menu", name: "actionMenu", maxHeight: "400", style: "width: 200px;", components: [
{action: "bookmarks", classes: "menu-item", components: [
{kind: "onyx.IconButton", src: "assets/bookmarks.png"},
{content: $L("Bookmarks"), classes: "menu-label"}
@@ -99,7 +99,7 @@ enyo.kind({
currentModule: null,
passage: {
- osis: "Matt.1",
+ osisRef: "Matt.1",
label: "Matt 1",
chapter: 1
},
@@ -229,6 +229,7 @@ enyo.kind({
this.$.bcSelector.setModule(this.currentModule);
//Load the verses
+ //console.log(this.passage, this.settings);
if(this.passage === this.settings.lastRead || !this.settings.lastRead)
this.handlePassage(this.passage);
if(this.settings)
@@ -271,6 +272,7 @@ enyo.kind({
//Persist current passage
this.addToHistory(this.passage);
+ this.renderHistory();
this.settings["lastRead"] = this.passage;
api.put(this.settings);
@@ -281,6 +283,7 @@ enyo.kind({
},
handlePassage: function (inOsis) {
+ //console.log("handlePassage", inOsis, this.passage);
this.verses = [];
this.$.verseList.setCount(this.verses.length);
this.$.verseList.refresh();
@@ -301,7 +304,7 @@ enyo.kind({
chapter: parseInt(inOsis.split(".")[1], 10)
};
}
-
+ this.$.btnPassage.setContent((this.passage.label) ? this.passage.label : api.formatOsis(this.passage.osisRef));
this.loadText(this.passage.osisRef, enyo.bind(this, function (inError, inResult) {
if(!inError) {
this.footnotes = inResult.footnotes;
@@ -325,7 +328,6 @@ enyo.kind({
this.$.verseList.scrollToRow(verseNumber+1);
this.hasVerseNumber = verseNumber+1;
}
- this.renderHistory();
} else {
if(inError.code && inError.code === 123) {
//handle old internal module format
@@ -333,14 +335,6 @@ enyo.kind({
this.handleError(inError.message);
}
}));
-
- //Set passage positions
- /*this.firstTop = true;
- this.firstBottom = true;
- this.passagePos.middle = this.passage.osisRef;
- this.passagePos.top = sword.verseKey.previous(this.passage.osisRef, this.currentModule.config.Versification).osisRef;
- this.passagePos.bottom = sword.verseKey.next(this.passage.osisRef, this.currentModule.config.Versification).osisRef;
- */
},
setVerses: function (inSender, inEvent) {