Cancelling DeviceFactory creation still creates a device

Posted on
Fri Nov 02, 2018 4:00 pm
FlyingDiver offline
User avatar
Posts: 7222
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Cancelling DeviceFactory creation still creates a device

Even if I cancel out of the creation dialog, and never call indigo.device.create(), a device is still created.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Fri Nov 02, 2018 4:12 pm
jay (support) offline
Site Admin
User avatar
Posts: 18220
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Cancelling DeviceFactory creation still creates a device

Yep - it's the same for any device, as soon as you select a device type in the new device dialog a device is created at that point.

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Fri Nov 02, 2018 4:22 pm
FlyingDiver offline
User avatar
Posts: 7222
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: Cancelling DeviceFactory creation still creates a device

What's the best way to get that device ID so I can delete it?

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Fri Nov 02, 2018 4:40 pm
jay (support) offline
Site Admin
User avatar
Posts: 18220
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Cancelling DeviceFactory creation still creates a device

Not sure. Given that that is expected behavior from all other device creations, any special reason you want to delete it automatically?

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Fri Nov 02, 2018 4:44 pm
FlyingDiver offline
User avatar
Posts: 7222
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: Cancelling DeviceFactory creation still creates a device

jay (support) wrote:
Not sure. Given that that is expected behavior from all other device creations, any special reason you want to delete it automatically?


Because the way the DeviceFactory works, if they don't complete the creation process completely it's a useless device. At least for this specific plugin.

I can probably just iterate through the devices assigned to the plugin and figure out which one it is.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Fri Nov 02, 2018 7:45 pm
jay (support) offline
Site Admin
User avatar
Posts: 18220
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Cancelling DeviceFactory creation still creates a device

That's what happens to other devices as well when they cancel out of the configuration dialog...

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Fri Nov 02, 2018 7:48 pm
FlyingDiver offline
User avatar
Posts: 7222
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: Cancelling DeviceFactory creation still creates a device

jay (support) wrote:
That's what happens to other devices as well when they cancel out of the configuration dialog...


I understand that it's the current standard behavior, but I don't think it's a good UX. If I can clean it up, is there a good reason I shouldn't?

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Fri Nov 02, 2018 9:58 pm
jay (support) offline
Site Admin
User avatar
Posts: 18220
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Cancelling DeviceFactory creation still creates a device

I prefer consistency - even worse UX (IMO) is something that works inconsistently with other similar actions. It's like those old windows ports to the Mac where things were just different enough for them to feel un-Mac-like...

But that's just me. :)

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Mon Nov 05, 2018 1:07 am
howartp offline
Posts: 4559
Joined: Jan 09, 2014
Location: West Yorkshire, UK

Re: Cancelling DeviceFactory creation still creates a device

Do I recall an equivalent to $isFullyConfigured in the device properties?


Sent from my iPhone using Tapatalk Pro

Posted on
Mon Nov 05, 2018 7:56 am
matt (support) offline
Site Admin
User avatar
Posts: 21417
Joined: Jan 27, 2003
Location: Texas

Re: Cancelling DeviceFactory creation still creates a device

Yes: dev.configured

Image

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 5 guests