cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Bowser <bows...@gmail.com>
Subject Re: [Discuss] Why was device.name removed from the device-plugin?
Date Sat, 18 Jun 2016 00:39:18 GMT
The Bluetooth plugin, or a third party plugin.  It does not belong in
Device.

On Fri, Jun 17, 2016, 5:23 PM Philipp Kursawe <phil.kursawe@gmail.com>
wrote:

> > that might bring some trouble if the device doesn't have
> bluetooth. We should decide what to return in that case, nothing? and
> document it
>
> We return manufactur + model in that case.
>
> @Joe: the devices I checked had pretty useful BT sharing names. And it is
> functionality belonging to the device. Where else would it belong to?
>
> On Sat, Jun 18, 2016 at 12:42 AM, Joe Bowser <bowserj@gmail.com> wrote:
>
> > -1
> >
> > This is a new feature and something we never supported.
> >
> > The model feature was the user-readable type of phone on Android (i.e.
> > Nexus 5X) where the name was the in-house codename for it, in this case
> > bullhead.  When we switched to device.model, we removed device.name.
> > Getting the Bluetooth sharing name could literally be anything like
> > "MyHovercraftIsFullOfEels" or "ThisRentalCarSucks".
> >
> > This is entirely new functionality, and I think that it should exist in a
> > separate plugin.
> >
> >
> >
> > On Fri, Jun 17, 2016 at 3:25 PM, julio cesar sanchez <
> > jcesarmobile@gmail.com
> > > wrote:
> >
> > > +1
> > >
> > > The only thing I see is the plugin he points get the android name from
> > the
> > > bluetooth adapter, that might bring some trouble if the device doesn't
> > have
> > > bluetooth. We should decide what to return in that case, nothing? and
> > > document it
> > >
> > > 2016-06-18 0:15 GMT+02:00 Shazron <shazron@gmail.com>:
> > >
> > > > I have no objection if the API property is unambiguous, unlike what
> it
> > > was
> > > > before (over 4 years ago!), and is supported by all the major
> platforms
> > > > (looks like it is, from what you mentioned). Also -- Ubuntu/Linux
> looks
> > > > like its just /etc/hostname. We'll just have to bump a minor version.
> > > >
> > > > What do the others think?
> > > >
> > > >
> > > >
> > > > On Fri, Jun 17, 2016 at 3:07 PM, Philipp Kursawe <
> > phil.kursawe@gmail.com
> > > >
> > > > wrote:
> > > >
> > > > > To further emphasize one point. I fully agree with moving from
> > > > device.name
> > > > > to device.model + device.manufacturer + device.platform.
> > > > > But I still ask all of you do consider bringing back a proper
> > > > device.name.
> > > > > As I wrote, on Windows its pretty easy to get the real name of the
> > > > > PC/Phone. On iOS and Android the work is already done.
> > > > >
> > > > > On Sat, Jun 18, 2016 at 12:02 AM, Philipp Kursawe <
> > > > phil.kursawe@gmail.com>
> > > > > wrote:
> > > > >
> > > > > > Thanks for pointing this out. However the name is not used to
> > > reference
> > > > > > the device to the API. Thats what the device.uuid is being used
> > for.
> > > > The
> > > > > > device name is used in the UI where the user can see its API
> > enabled
> > > > > > devices. You don't want to show the user the device id there
> (cause
> > > she
> > > > > has
> > > > > > no point of reference to which physical device it belongs) but
> the
> > > name
> > > > > she
> > > > > > gave her phone and knows her phone when she connects it to
> itunes,
> > > > iphoto
> > > > > > etc.
> > > > > >
> > > > > > So the reason to introduce the name property back is exactly
the
> > one
> > > > you
> > > > > > mentioned: The user can always change the name of her phone
and
> > there
> > > > > knows
> > > > > > its name and will recognize it in a list of devices.
> > > > > >
> > > > > > On Fri, Jun 17, 2016 at 9:23 PM, Shazron <shazron@gmail.com>
> > wrote:
> > > > > >
> > > > > >> Hi Philipp,
> > > > > >> This was the rationale:
> > > > > >>
> > > > > >>
> > > > >
> > > >
> > >
> >
> https://lists.apache.org/thread.html/e3b0e5f87ba3929d5578308b25ee9a6af5b91177b94015878970fa8e@1352248856@%3Cdev.cordova.apache.org%3E
> > > > > >>
> > > > > >> On iOS,  [UIDevice name] returns the name the user sets
in
> iTunes
> > > for
> > > > > >> their
> > > > > >> device i.e. "Shazron's iPhone 4", and can change anytime
so
> > relying
> > > on
> > > > > it
> > > > > >> for API access would be problematic.
> > > > > >>
> > > > > >>
> > > > > >> On Fri, Jun 17, 2016 at 1:51 AM, Philipp Kursawe <
> > > > > phil.kursawe@gmail.com>
> > > > > >> wrote:
> > > > > >>
> > > > > >> > I wonder why such an important piece of information
is not
> > > provided
> > > > > >> anymore
> > > > > >> > in the device plugin?
> > > > > >> > What was the reason to remove the property?
> > > > > >> >
> > > > > >> > The name of the device, especially when users can
> > authorise/revoke
> > > > API
> > > > > >> > access to apps on different devices, is an important
variable
> to
> > > > know.
> > > > > >> >
> > > > > >> > There is a plugin that brings back this functionality
for
> > Android,
> > > > iOS
> > > > > >> and
> > > > > >> > for Windows it would be a one-liner only too.
> > > > > >> > https://github.com/becvert/cordova-plugin-device-name
> > > > > >> >
> > > > > >>
> > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message