Return-Path: X-Original-To: apmail-cordova-dev-archive@www.apache.org Delivered-To: apmail-cordova-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 16BDE10AE9 for ; Tue, 4 Mar 2014 17:33:51 +0000 (UTC) Received: (qmail 90879 invoked by uid 500); 4 Mar 2014 17:33:30 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 90752 invoked by uid 500); 4 Mar 2014 17:33:28 -0000 Mailing-List: contact dev-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list dev@cordova.apache.org Received: (qmail 90637 invoked by uid 99); 4 Mar 2014 17:33:24 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 04 Mar 2014 17:33:24 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of brian.leroux@gmail.com designates 209.85.213.180 as permitted sender) Received: from [209.85.213.180] (HELO mail-ig0-f180.google.com) (209.85.213.180) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 04 Mar 2014 17:33:18 +0000 Received: by mail-ig0-f180.google.com with SMTP id hl1so1993154igb.1 for ; Tue, 04 Mar 2014 09:32:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=Q8OfKqtQ7t+7a/tba2ulBI5FWA+sxM158aH1QkRm4so=; b=Lj/I8PiFaXeVOzsoVwuOyJRAJMJiGIuQz/fPBAn8xAgo7FYR536k2BheSwbYT7T2tG mEJ+M5DMcH85BLvRiHUk9sXcfncTe/jxVDiwZQROCn9A3wpJH1gpVB9SU9MJQ2EAyNI5 Suw7arfa9Vu2XJsto2eh/kb4ncVKA1nBrb6Rs1xHHym+NX6psvg0A60BjU7yrWoITFVE OALMCocALoPnrAr6JLgJQhcqDsiAwtpzzu+BZAB3fJ8k7NOZGuUKExwuMJUlRxh0ugvb f2J7s0N2QFsRZX6zWwsLOrkB43X6b3pBCYAczRJ+cp9ggzyCwk7/vJxAb2UlTuXft+zD MO1w== MIME-Version: 1.0 X-Received: by 10.50.115.102 with SMTP id jn6mr29752983igb.10.1393953935627; Tue, 04 Mar 2014 09:25:35 -0800 (PST) Sender: brian.leroux@gmail.com Received: by 10.50.213.35 with HTTP; Tue, 4 Mar 2014 09:25:35 -0800 (PST) In-Reply-To: References: Date: Tue, 4 Mar 2014 09:25:35 -0800 X-Google-Sender-Auth: HMHWyS10tgeVCRpD2Yylp9bSyT4 Message-ID: Subject: Re: How to implement the navigator.notification in Firefox OS? From: Brian LeRoux To: "dev@cordova.apache.org" Cc: Michal Mocny Content-Type: multipart/alternative; boundary=089e0117683b2a9f0704f3cb31e7 X-Virus-Checked: Checked by ClamAV on apache.org --089e0117683b2a9f0704f3cb31e7 Content-Type: text/plain; charset=ISO-8859-1 oooh dirty I like it On Tue, Mar 4, 2014 at 9:17 AM, Michal Mocny wrote: > Ah wait, that won't inject it into the page.. Sorry, misunderstood the > problem. > > Why not just write JS that runs on startup (after domcontentready but > delaying onpluginready) that injects the CSS? > > > On Tue, Mar 4, 2014 at 12:07 PM, Michal Mocny wrote: > > > ? > > > http://cordova.apache.org/docs/en/edge/plugin_ref_spec.md.html#Plugin%20Specification_asset_element > > > > > > On Tue, Mar 4, 2014 at 11:45 AM, Brian LeRoux wrote: > > > >> Seems to me that you want the plugin installation to copy the css file. > >> its > >> hacky, but you could use [1] as a workaround and file a bug to > >> add other file types for copying. > >> > >> http://cordova.apache.org/docs/en/3.0.0/plugin_ref_spec.md > >> > >> > >> On Mon, Mar 3, 2014 at 11:51 PM, Robber Phex > >> wrote: > >> > >> > I suggest some method to solve it. > >> > > >> > First, we can make a rule that cordova-plugin-dialogs must work with > >> > notification.css. and, plugin will create a null css in android for > >> avoid > >> > warming. we also update document. > >> > > >> > Second, in HTML, cordova-plugin-dialogs can work without link to > >> > notification.css. and, the android platform is no problem, but in > >> Firefox > >> > OS, the js will add link to notification.css dynamically. > >> > > >> > All in all, I think the plugin must provide a single method to use it. > >> same > >> > code worked in Firefox OS, but warming in Android is not good enough. > >> > > >> > > >> > On Tue, Mar 4, 2014 at 2:30 PM, Robber Phex > >> wrote: > >> > > >> > > I think, If the developer must add notification.css, we should > update > >> the > >> > > document as soon as possible. > >> > > > >> > > such as > >> > > > >> > > >> > http://cordova.apache.org/docs/en/3.3.0/cordova_notification_notification.md.html#Notification > >> > > > >> > > In last, I don't think it is good idea that let app show some > warming > >> in > >> > > android. I suggest the plugin solve it. > >> > > > >> > > > >> > > On Tue, Mar 4, 2014 at 9:30 AM, Carlos Santana < > csantana23@gmail.com > >> > >wrote: > >> > > > >> > >> The firefox documentation for the plugin [1] states that the user > >> needs > >> > to > >> > >> add the css entry in index.html > >> > >> > >> > >> /> > >> > >> > >> > >> I don't completely understand the problem with android. > >> > >> Are you referring to the fact that you wan to use same index.html > for > >> > both > >> > >> android and firefox and that the notification.css will be missing > for > >> > >> android platform? > >> > >> If that is the case use the merges to customize each platform. > >> > >> > >> > >> in your case you can put an empty file in > >> merges/css/notifications.css > >> > >> > >> > >> The cordova docs [2] explains a similar use case. > >> > >> > >> > >> If you are looking to enhance the plugin to inject the css > >> dynamically > >> > you > >> > >> will need to do that from the plugin's javascript for firefox > located > >> > here > >> > >> [3] > >> > >> > >> > >> > >> > >> [1]: > >> > >> > >> > >> > >> > > >> > https://github.com/apache/cordova-plugin-dialogs/blob/master/doc/index.md#firefox-os-quirks > >> > >> [2]: > >> > >> > >> > >> > >> > > >> > http://cordova.apache.org/docs/en/3.4.0/guide_cli_index.md.html#The%20Command-Line%20Interface > >> > >> [3]: > >> > >> > >> > >> > >> > > >> > https://github.com/apache/cordova-plugin-dialogs/blob/dev/src/firefoxos/notification.js > >> > >> > >> > >> > >> > >> > >> > >> On Mon, Mar 3, 2014 at 2:49 AM, Robber Phex > >> > wrote: > >> > >> > >> > >> > There is anyone? > >> > >> > > >> > >> > I found that the plug "cordova-plugin-dialogs" is already > implement > >> > the > >> > >> > navigator.notification, but it need refer the CSS file > >> > >> > "css/notification.css" in Firefox OS. > >> > >> > > >> > >> > This is a dilemma: > >> > >> > > >> > >> > If we consider Firefox OS, we must add link tag with > >> > >> css/notification.css, > >> > >> > but in android, the log display "AndroidProtocolHandler(2620): > >> Unable > >> > to > >> > >> > open asset URL: file:///android_asset/www/css/notification.css" > >> > >> > > >> > >> > Or, if we not refer "css/notification.css", The > >> navigator.notification > >> > >> will > >> > >> > not work at Firefox OS. such as CB-6154: > >> > >> > https://issues.apache.org/jira/browse/CB-6145 > >> > >> > > >> > >> > > >> > >> > Do someone have a solution? > >> > >> > > >> > >> > > >> > >> > On Mon, Mar 3, 2014 at 7:31 AM, Robber Phex < > robberphex@gmail.com> > >> > >> wrote: > >> > >> > > >> > >> > > Hi,all. > >> > >> > > > >> > >> > > I found CB-6154, and I want to know how to fix it gracefully, > >> how to > >> > >> > > implement navigator.notification gracefully in FIrefox OS? > >> > >> > > > >> > >> > > CB-6154:https://issues.apache.org/jira/browse/CB-6145 > >> > >> > > > >> > >> > > Any suggestion is welcome! > >> > >> > > Thanks. > >> > >> > > > >> > >> > > -- > >> > >> > > Regards, > >> > >> > > RobberPhex > >> > >> > > > >> > >> > > About me: http://about.me/RobberPhex > >> > >> > > > >> > >> > > >> > >> > > >> > >> > > >> > >> > -- > >> > >> > Regards, > >> > >> > RobberPhex > >> > >> > > >> > >> > About me: http://about.me/RobberPhex > >> > >> > > >> > >> > >> > >> > >> > >> > >> > >> -- > >> > >> Carlos Santana > >> > >> > >> > >> > >> > > > >> > > > >> > > > >> > > -- > >> > > Regards, > >> > > RobberPhex > >> > > > >> > > About me: http://about.me/RobberPhex > >> > > > >> > > >> > > >> > > >> > -- > >> > Regards, > >> > RobberPhex > >> > > >> > About me: http://about.me/RobberPhex > >> > > >> > > > > > --089e0117683b2a9f0704f3cb31e7--