Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Wrong selection in wxListBox on Mac OS X, wxWidgets 2.9.4
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  6 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Daniel Dekkers  
View profile  
 More options Sep 26 2012, 6:44 am
From: Daniel Dekkers <d.dekk...@cthrough.nl>
Date: Wed, 26 Sep 2012 03:44:44 -0700 (PDT)
Local: Wed, Sep 26 2012 6:44 am
Subject: Wrong selection in wxListBox on Mac OS X, wxWidgets 2.9.4

Hi,

When I do...

m_ListBox->Insert(wxT("Entry0"), 0);
m_ListBox->Insert(wxT("Entry1"), 1);
m_ListBox->Insert(wxT("Entry2"), 2);
m_ListBox->Select(1);
m_ListBox->Delete(0);

... "Entry2" ends up as the current selection on Mac OS X. This can't be
right.
On Windows, "Entry1" is the (correct) result.

Any way to avoid this, or is wxListBox deprecated in favour of wxListCtrl?

Thanks,
Daniel Dekkers


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Vadim Zeitlin  
View profile  
 More options Sep 26 2012, 7:00 am
From: Vadim Zeitlin <va...@wxwidgets.org>
Date: Wed, 26 Sep 2012 13:00:19 +0200
Local: Wed, Sep 26 2012 7:00 am
Subject: Re: [wx-dev] Wrong selection in wxListBox on Mac OS X, wxWidgets 2.9.4

On Wed, 26 Sep 2012 03:44:44 -0700 (PDT) Daniel Dekkers wrote:

DD> When I do...
DD>  
DD> m_ListBox->Insert(wxT("Entry0"), 0);
DD> m_ListBox->Insert(wxT("Entry1"), 1);
DD> m_ListBox->Insert(wxT("Entry2"), 2);
DD> m_ListBox->Select(1);
DD> m_ListBox->Delete(0);
DD>  
DD> ... "Entry2" ends up as the current selection on Mac OS X. This can't be
DD> right.

 No, it looks like a bug. I believe we even have unit test for this one but
it might be disabled under OS X as quite a few other tests right now.

 Which port (Carbon or Cocoa) do you use?

DD> Any way to avoid this, or is wxListBox deprecated in favour of wxListCtrl?

 No, it's not deprecated, the bug "just" needs to be fixed.

 Regards,
VZ

  application_pgp-signature_part
< 1K Download

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Daniel Dekkers  
View profile  
 More options Sep 26 2012, 11:03 am
From: Daniel Dekkers <d.dekk...@cthrough.nl>
Date: Wed, 26 Sep 2012 17:03:53 +0200
Local: Wed, Sep 26 2012 11:03 am
Subject: Re: [wx-dev] Wrong selection in wxListBox on Mac OS X, wxWidgets 2.9.4
Hi,

I'm using the Cocoa framework.
Avoided the problem by using wxListView, which I should have done anyway because i want drag&drop functionality.

Found another thing that feels like a bug though: wxTextCtrls don't get a kill focus event when a different window is selected (parent window of the wxTextCtrl loses focus).
On Windows they do. I'll try to figure out how to file bug reports for wxWidgets.

Thanks,
Daniel

On Sep 26, 2012, at 1:00 PM, Vadim Zeitlin wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Vadim Zeitlin  
View profile  
 More options Sep 26 2012, 12:21 pm
From: Vadim Zeitlin <va...@wxwidgets.org>
Date: Wed, 26 Sep 2012 18:21:08 +0200
Local: Wed, Sep 26 2012 12:21 pm
Subject: Re[2]: [wx-dev] Wrong selection in wxListBox on Mac OS X, wxWidgets 2.9.4

On Wed, 26 Sep 2012 17:03:53 +0200 Daniel Dekkers wrote:

DD> I'm using the Cocoa framework.

 Please open a ticket on trac.wxwidgets.org for this bug. Please check if
you can reproduce it in the listbox page of the widgets sample.

DD> Found another thing that feels like a bug though: wxTextCtrls don't get
DD> a kill focus event when a different window is selected (parent window
DD> of the wxTextCtrl loses focus).

 Again, please check if you can reproduce the problem in the text sample
and open a ticket if so (and if not, please try to find what do you do
differently in your code that results in different behaviour).

 Also, please search the existing tickets, the latter problem might have
been already reported, I have some vague memories of already seeing
something like this.

 Thanks,
VZ

  application_pgp-signature_part
< 1K Download

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Daniel Dekkers  
View profile  
 More options Oct 6 2012, 2:11 pm
From: Daniel Dekkers <d.dekk...@cthrough.nl>
Date: Sat, 6 Oct 2012 20:11:26 +0200
Local: Sat, Oct 6 2012 2:11 pm
Subject: Re: [wx-dev] Wrong selection in wxListBox on Mac OS X, wxWidgets 2.9.4

On Sep 26, 2012, at 6:21 PM, Vadim Zeitlin wrote:

> On Wed, 26 Sep 2012 17:03:53 +0200 Daniel Dekkers wrote:

> DD> I'm using the Cocoa framework.

> Please open a ticket on trac.wxwidgets.org for this bug. Please check if
> you can reproduce it in the listbox page of the widgets sample.

I really can't because in the sample(s) there is no new selection made when the current selected item is deleted.
I'll create a small demo and add a ticket.

> DD> Found another thing that feels like a bug though: wxTextCtrls don't get
> DD> a kill focus event when a different window is selected (parent window
> DD> of the wxTextCtrl loses focus).

> Again, please check if you can reproduce the problem in the text sample
> and open a ticket if so (and if not, please try to find what do you do
> differently in your code that results in different behaviour).

> Also, please search the existing tickets, the latter problem might have
> been already reported, I have some vague memories of already seeing
> something like this.

Yes:
http://trac.wxwidgets.org/ticket/14142
I've added a comment and a small demo to that ticket.
Very annoying bug if you want to check (and maybe correct) the validity of user input in a wxTextCtrl without having to resort to some kind of "apply now" control path.
You don't want to check on every wxEVT_COMMAND_TEXT_UPDATED event either, while the user is still typing.

> Thanks,
> VZ

Thanks,
Daniel

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Vadim Zeitlin  
View profile  
 More options Oct 6 2012, 5:51 pm
From: Vadim Zeitlin <va...@wxwidgets.org>
Date: Sat, 6 Oct 2012 23:51:41 +0200
Local: Sat, Oct 6 2012 5:51 pm
Subject: Re[2]: [wx-dev] Wrong selection in wxListBox on Mac OS X, wxWidgets 2.9.4

On Sat, 6 Oct 2012 20:11:26 +0200 Daniel Dekkers wrote:

DD> On Sep 26, 2012, at 6:21 PM, Vadim Zeitlin wrote:
DD>
DD> > On Wed, 26 Sep 2012 17:03:53 +0200 Daniel Dekkers wrote:
DD> >
DD> > DD> I'm using the Cocoa framework.
DD> >
DD> > Please open a ticket on trac.wxwidgets.org for this bug. Please check if
DD> > you can reproduce it in the listbox page of the widgets sample.
DD>
DD> I really can't because in the sample(s) there is no new selection made
DD> when the current selected item is deleted.

 Please just add the missing parts to the sample and attach a patch with
your changes (please see http://trac.wxwidgets.org/wiki/HowToSubmitPatches
if you hadn't done this before) if possible.

DD> > DD> Found another thing that feels like a bug though: wxTextCtrls don't get
DD> > DD> a kill focus event when a different window is selected (parent window
DD> > DD> of the wxTextCtrl loses focus).
...
DD> Yes:
DD> http://trac.wxwidgets.org/ticket/14142
DD> I've added a comment and a small demo to that ticket.
DD> Very annoying bug if you want to check (and maybe correct) the validity of user input in a wxTextCtrl without having to resort to some kind of "apply now" control path.
DD> You don't want to check on every wxEVT_COMMAND_TEXT_UPDATED event either, while the user is still typing.

 Yes, this is indeed very annoying. I hope Stefan can look into this
though because you could summarize everything I know about focus handling
under Mac on a back of a post stamp with plenty of space remaining.

 Regards,
VZ

  application_pgp-signature_part
< 1K Download

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »