Not logged in. · Lost password · Register
Forum: agsXMPP RSS
Avatar
zackrspv #1
Member since Sep 2010 · 29 posts
Group memberships: Members
Show profile · Link to this post
Subject: Search Roster
When a user clicks the little red x to close the 'search roster' box.  How do we get it bacK?
Avatar
Alex #2
Member since Feb 2003 · 4297 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Control + F

see:
  1. private void treeView_KeyDown(object sender, KeyEventArgs e)
  2. {
  3.     if (e.Control && e.KeyCode == Keys.F)
  4.         toolStrip.Show();
  5. }

Alex
Avatar
zackrspv #3
Member since Sep 2010 · 29 posts
Group memberships: Members
Show profile · Link to this post
Alex:

When i click on the roster control, and press Ctrl+F, it just beeps at me.

I'm not using a custom roster, i'm using the Roster from the UI elements (i just plopped it on my form from the toolbox, and let the AutoRoster property take care of everything.

I do notice that it has 'toolstripbutton1', etc, when you hover over the buttons, but if you click on the 'red x' on the toolstrip, it hides the entire toolstrip.

As i havn't defined a custom toolstrip, the command 'toolStrip.Show()' doesn't seem to do anything. 

foreach (Control con in rosterControl1.Controls)
{
Console.Writeline(con.Name.toString());
}

gives me the option for toolstripcontainer1,  however, even if the red x is clicked on the search bar, all the values of 'visible', are still true, and doing .Show() on control[0].Show() doesnt do anything either.

Do i need to specify my own toolbar?  If i add my own toolbar to the roster control, will it not show the default one in there?

Do i just need to handle my own roster control (I prefer not to do this)?
Avatar
Alex #4
Member since Feb 2003 · 4297 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
for me it is working.
All the UI stuff is open source. So you can add the code directly to your project and extend it to your requirements.

Alex
Avatar
zackrspv #5
Member since Sep 2010 · 29 posts
Group memberships: Members
Show profile · Link to this post
I finally got it by including the 'roster' from the agsxmpp.ui folder into my project, like you stated.  Then changing the toolStrip modifiers to public, so that i can directly call the .Show() from the primary program.
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Forum: agsXMPP RSS