Re: [Cvslog] r26295 -in/lyx-devel/trunk/src/frontends/qt4:GuiSendto...

2008-09-04 Thread rgheck
Andre Poenitz wrote: On Thu, Sep 04, 2008 at 11:11:16PM +0200, Vincent van Ravesteijn - TNW wrote: It looks like currentRow() might return -1 sometimes You are right, if nothing is selected, it returns -1... Andre' Please correct me if I'm wrong (I'm just trying to understa

Re: [Cvslog] r26295 -in/lyx-devel/trunk/src/frontends/qt4:GuiSendto...

2008-09-04 Thread Andre Poenitz
On Thu, Sep 04, 2008 at 11:11:16PM +0200, Vincent van Ravesteijn - TNW wrote: > >> It looks like currentRow() might return -1 sometimes > > > >You are right, if nothing is selected, it returns -1... > > > >Andre' > > Please correct me if I'm wrong (I'm just trying to understand QT). > > I was a

RE: [Cvslog] r26295 -in/lyx-devel/trunk/src/frontends/qt4:GuiSendto...

2008-09-04 Thread Vincent van Ravesteijn - TNW
>> It looks like currentRow() might return -1 sometimes > >You are right, if nothing is selected, it returns -1... > >Andre' Please correct me if I'm wrong (I'm just trying to understand QT). I was a little vague in the above sentence on purpose, because when I was experimenting with this code

Re: [Cvslog] r26295 - in/lyx-devel/trunk/src/frontends/qt4:GuiSendto...

2008-09-04 Thread Andre Poenitz
On Thu, Sep 04, 2008 at 09:23:00PM +0200, Vincent van Ravesteijn - TNW wrote: > It looks like currentRow() might return -1 sometimes You are right, if nothing is selected, it returns -1... Andre'

RE: [Cvslog] r26295 - in/lyx-devel/trunk/src/frontends/qt4:GuiSendto...

2008-09-04 Thread Vincent van Ravesteijn - TNW
On Thu, Sep 04, 2008 at 09:04:21PM +0200, Vincent van Ravesteijn - TNW wrote: > >On Thu, Sep 04, 2008 at 09:36:45AM -, [EMAIL PROTECTED] wrote: > >> @@ -68,6 +71,13 @@ > >> { > >> all_formats_ = allFormats(); > >> > >> + // Save the current selection if any > >> + Format const *

RE: [Cvslog] r26295 - in /lyx-devel/trunk/src/frontends/qt4:GuiSendto...

2008-09-04 Thread Vincent van Ravesteijn - TNW
>On Thu, Sep 04, 2008 at 09:36:45AM -, [EMAIL PROTECTED] wrote: >> @@ -68,6 +71,13 @@ >> { >> all_formats_ = allFormats(); >> >> + // Save the current selection if any >> + Format const * current_format = 0; >> + int const line = formatLW->currentRow(); >> + if (line >=

Re: [Cvslog] r26295 - in /lyx-devel/trunk/src/frontends/qt4: GuiSendto...

2008-09-04 Thread Andre Poenitz
On Thu, Sep 04, 2008 at 09:36:45AM -, [EMAIL PROTECTED] wrote: > @@ -68,6 +71,13 @@ > { > all_formats_ = allFormats(); > > + // Save the current selection if any > + Format const * current_format = 0; > + int const line = formatLW->currentRow(); > + if (line >= 0 && lin