Re: [PATCH 2/2] Ticket #831 Fix

2015-03-10 Thread Joakim Bygdell
On 10 March 2015 at 10:19, Davide DB dbdav...@gmail.com wrote: On Tue, Mar 10, 2015 at 6:52 AM, Joakim Bygdell j.bygd...@gmail.com wrote: The default cylinder setup is more suited to people that do not dive the way you do, since the way you describe it you rarely start a dive on backgas.

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-10 Thread Joakim Bygdell
On 10 March 2015 at 12:08, Davide DB dbdav...@gmail.com wrote: If I recall it correctly, I remember that some developer told me that having at least a cylinder is compulsory. Why? When I import dives from my Viper in gauge mode, the cylinder table is originally empty. When I import from my

[PATCH 2/2] Ticket #831 Fix

2015-03-10 Thread Willem Ferguson
Dirk and Tomaz, How easy would it be to implement reordering the cylinders in the equipment tab after they have been copy-and- pasted from another dive, that is, without having to delete and re-type all the information for a cylinder? The present setup is not very user-friendly for divers using

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-10 Thread Davide DB
If I recall it correctly, I remember that some developer told me that having at least a cylinder is compulsory. Why? When I import dives from my Viper in gauge mode, the cylinder table is originally empty. When I import from my Xdeep I have a unkonwn cylinder (it's logged into the imported uddf

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-10 Thread Robert Helling
Hi all, On 10.03.2015, at 06:52, Joakim Bygdell j.bygd...@gmail.com wrote: The default cylinder setup is more suited to people that do not dive the way you do, since the way you describe it you rarely start a dive on backgas. It’s just a way to make it convenient for people that doesn’t

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-10 Thread Davide DB
On Tue, Mar 10, 2015 at 12:52 PM, Joakim Bygdell j.bygd...@gmail.com wrote: You can change back to the first gas later in the dive if you have done a switch to another gas. If you have say 4 different gas mixes during a dive you can have a gas change series that does not follow the order

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Dirk Hohndel
On Mon, Mar 09, 2015 at 07:49:47AM +0200, Yosef Hamza wrote: Those 2 patches are actually one, But I think that the second patch needs some discussion. As Robert already mentioned, the second patch (0003) is simply wrong. That code was there for a reason :-) I think it's better this way

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Davide DB
Il 09/mar/2015 18:36 Dirk Hohndel d...@hohndel.org ha scritto: That's a strange edge case. Here are some assumptions that we tend to make a) most people get the data into Subsurface via a download from their dive computer (or, initially, importing from other software). b) if there are errors

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Henrik Brautaset Aronsen
On 09 Mar 2015, at 19:24, Davide DB dbdav...@gmail.com wrote: Il 09/mar/2015 18:36 Dirk Hohndel d...@hohndel.org ha scritto: So basically it seems rather unlikely that the user really has the wrong order of tanks and needs to switch to a different tank. Dirk, does this means that

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Yosef Hamza
About patch -0002- The thing is timeAxis-valueAt(scenePos) can return a negative value if the cursor was pointing to the negative part of the axis to the left, which is the case here. The unsigned assigning happens at the very end of assigning series when assigned finally to duration_t of event

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Dirk Hohndel
On Mon, Mar 09, 2015 at 06:48:52PM +0200, Yosef Hamza wrote: About patch -0002- The thing is timeAxis-valueAt(scenePos) can return a negative value if the cursor was pointing to the negative part of the axis to the left, which is the case here. The unsigned assigning happens at the very

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Dirk Hohndel
On Mon, Mar 09, 2015 at 07:26:05PM +0100, Henrik Brautaset Aronsen wrote: On 09 Mar 2015, at 19:24, Davide DB dbdav...@gmail.com wrote: Il 09/mar/2015 18:36 Dirk Hohndel d...@hohndel.org ha scritto: So basically it seems rather unlikely that the user really has the wrong order of tanks

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Dirk Hohndel
On Mon, Mar 09, 2015 at 07:24:15PM +0100, Davide DB wrote: Il 09/mar/2015 18:36 Dirk Hohndel d...@hohndel.org ha scritto: That's a strange edge case. Here are some assumptions that we tend to make a) most people get the data into Subsurface via a download from their dive computer (or,

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Yosef Hamza
On Tue, Mar 10, 2015 at 1:18 AM, Dirk Hohndel d...@hohndel.org wrote: @@ -1392,6 +1395,23 @@ void ProfileWidget2::changeGas() qDebug() failed to parse tank number; tank = get_gasidx(displayed_dive, gasmix); } + + struct event **events =

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Yosef Hamza
Here's the proposed change by Robert fixes the problem for all. It doesn't show the gas change icon @0:00, But you can still change gases @0:00. §Yousef On Mon, Mar 9, 2015 at 10:42 PM, Dirk Hohndel d...@hohndel.org wrote: On Mon, Mar 09, 2015 at 07:26:05PM +0100, Henrik Brautaset Aronsen

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Dirk Hohndel
On Tue, Mar 10, 2015 at 12:52:16AM +0200, Yosef Hamza wrote: Here's the proposed change by Robert fixes the problem for all. Well, it may fix one problem, but using that patch would create a lot of others... This whole two patch rule is about making sure you understand how to submit changes and

Re: [PATCH 2/2] Ticket #831 Fix

2015-03-09 Thread Davide DB
On Mon, Mar 9, 2015 at 9:42 PM, Dirk Hohndel d...@hohndel.org wrote: If this is actually a show stopper for you guys, then I'll try to get in a hack so you can use the software, but a real solution will likely take a little longer. No problem at all, I can live with them. In the last few

[PATCH 2/2] Ticket #831 Fix

2015-03-08 Thread Yosef Hamza
Those 2 patches are actually one, But I think that the second patch needs some discussion. I think it's better this way because through trying and fixing the error there wasn't a way -that I'm aware of at least- to cancel the added event @0:00. §Yousef 0003-Display-gas-change-event-0-0.patch