From callback-dev-return-4350-apmail-incubator-callback-dev-archive=incubator.apache.org@incubator.apache.org Tue Apr 3 22:46:43 2012 Return-Path: X-Original-To: apmail-incubator-callback-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-callback-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 5654D9C5C for ; Tue, 3 Apr 2012 22:46:43 +0000 (UTC) Received: (qmail 43838 invoked by uid 500); 3 Apr 2012 22:46:43 -0000 Delivered-To: apmail-incubator-callback-dev-archive@incubator.apache.org Received: (qmail 43778 invoked by uid 500); 3 Apr 2012 22:46:43 -0000 Mailing-List: contact callback-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: callback-dev@incubator.apache.org Delivered-To: mailing list callback-dev@incubator.apache.org Received: (qmail 43770 invoked by uid 99); 3 Apr 2012 22:46:43 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Apr 2012 22:46:43 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of shazron@gmail.com designates 209.85.210.175 as permitted sender) Received: from [209.85.210.175] (HELO mail-iy0-f175.google.com) (209.85.210.175) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Apr 2012 22:46:36 +0000 Received: by iaag37 with SMTP id g37so295210iaa.6 for ; Tue, 03 Apr 2012 15:46:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type:content-transfer-encoding; bh=EoKYCYNk6O7tJJN3s/7ERTNsZayxXaAwUOqUi+DgA0w=; b=QbxhQun9PI3YkcqTQLH3mXKoNmapq2vAqhm2oOAr3iDa1CxXLwqxNQRp9fDvUntt7X 6ZRnBoYYvihEr780dKskOH8mX3/KbaTzB7fvaN8tRzkF9+EFWHWV8WZsN5uqANkT642Z ygGY4uINMvU4ZNP5zMU37WD4kGrd3czEvsIlwCA7cqCMPwCcNCX3Ar9LQnkrT/UK2D4A 4S0Z650k01Xpp4QPZj+oyQuV6EUprz5UApwgkeCAp8WDAG2LUeCmNUj0WDo44qpUH6jc M/vdlSCpplFavlYQjdVKN33OBhZMmlkEySaHWki84nQniyP3U6ckLas752/AsLw+UUB6 KmMw== Received: by 10.50.47.231 with SMTP id g7mr3425080ign.12.1333493176092; Tue, 03 Apr 2012 15:46:16 -0700 (PDT) MIME-Version: 1.0 Received: by 10.42.138.72 with HTTP; Tue, 3 Apr 2012 15:45:35 -0700 (PDT) In-Reply-To: <416329630-1333491106-cardhu_decombobulator_blackberry.rim.net-2094387235-@b18.c19.bise6.blackberry> References: <416329630-1333491106-cardhu_decombobulator_blackberry.rim.net-2094387235-@b18.c19.bise6.blackberry> From: Shazron Date: Tue, 3 Apr 2012 15:45:35 -0700 Message-ID: Subject: Re: Passing parameters to camera.getPicture instead of object -WHY? To: callback-dev@incubator.apache.org, gtanner@gmail.com Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org Gord - the OP's problem is not how to pass it in, but the signature change in JS which affects Obj-C core plugins (was options object, now options are arguments) imo changing the exec signature however, should be another discussion.. On Tue, Apr 3, 2012 at 3:11 PM, wrote: > If someone wanted an options arg why couldn't they just pass: > > [{f: 2, a: 1}] > > I think I am just missing the need to choose one or the other, where the = array seems fine. > > > Sent on the TELUS Mobility network with BlackBerry > > -----Original Message----- > From: Becky Gibson > Date: Tue, 3 Apr 2012 17:27:33 > To: > Reply-To: callback-dev@incubator.apache.org > Subject: Re: Passing parameters to camera.getPicture instead of object -W= HY? > > Ok, so to support iOS camera.getPicture for this release, I need to add 3 > more arguments to the takePicture device api - bringing the total up to 1= 0! > =A0And then in 1.7, we get to undo all of this work - wtf? =A0And, just f= or the > record, =A0the call to exec from the Android 1.4.1 camera.getPicture() > =A0accepted an options parameter =A0and passed those to CameraLauncher.ja= va as > an object. > > sorry, but I'm just a bit cranky as I keep discovering all of the things > that are broken in unified JS. > > -b > > On Tue, Apr 3, 2012 at 4:57 PM, Shazron wrote: > >> Hi Fil, >> Just to make sure since I have to verify all the APIs don't use the >> options object anymore and possibly fix those -- this was done across >> the board, true? >> >> Yeah lets do a hashmap thing for arguments in some future release, >> indexed arguments are brittle. >> >> Shaz >> >> On Tue, Apr 3, 2012 at 1:51 PM, Shazron wrote: >> > My guess is this change was to match the Android side, I had to make >> > the same change for Notification API, which broke because of this. >> > >> > On Tue, Apr 3, 2012 at 1:44 PM, Becky Gibson >> wrote: >> >> Somehow I missed this change in unified JS. Why are we now passing an >> array >> >> of parameters to getPicture rather than an options object? =A0 By pas= sing >> the >> >> object, we allowed people to easily extend the getPicture api by just >> >> adding their new option into an options object and modifying their co= py >> of >> >> the device specific camera implementation. They did not have to modif= y >> the >> >> PhoneGap/Cordova.js implementation (at least on the iOS side). =A0Now= , in >> >> order to add a new parameter to getPicture, you need to modify the JS= as >> >> well to pass yet another parameter into getPicture - the list is alre= ady >> >> long and we have lost some of the iOS options that were available. >> >> >> >> curious minds are a dangerous thing...... >> >