From 763df87ad0cba61fcb28a78bef9ebe0e7cb0bda6 Mon Sep 17 00:00:00 2001 From: Morgan McMillian Date: Sun, 11 Mar 2012 20:37:33 -0400 Subject: [PATCH] temporary hack for richtext kind on webworks --- app/source/TodoEdit.js | 2 +- app/source/TodoTxt.js | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/app/source/TodoEdit.js b/app/source/TodoEdit.js index c4176b0..a208017 100644 --- a/app/source/TodoEdit.js +++ b/app/source/TodoEdit.js @@ -45,7 +45,7 @@ enyo.kind({ {kind: "Button", caption: "+", onclick: "showInsert"} ] }, - {flex: 1, kind: "Scroller", components: [ + {flex: 1, name: "scroller", kind: "Scroller", components: [ {kind: "RichText", name: "tododetail", richContent: false}, ]}, {name: "editToolbar", kind: "Toolbar", pack: "justify", className: "enyo-toolbar-light", diff --git a/app/source/TodoTxt.js b/app/source/TodoTxt.js index 0f921f1..ce58395 100644 --- a/app/source/TodoTxt.js +++ b/app/source/TodoTxt.js @@ -96,6 +96,12 @@ enyo.kind({ } else if (window.blackberry) { this.os = "BlackBerry"; this.dirs = blackberry.io.dir.appDirs; + // hack for RichText not working properly + this.$.editView.$.tododetail.destroy(); + this.$.editView.$.scroller.createComponent( + {kind: "Input", name: "tododetail", owner:this.$.editView} + ); + this.$.editView.render(); } else { this.os = "unknown"; }