★ wanayoo — archive 1999 http://developer.iplanet.com/docs/examples/plugins/hotkeys.htmlNouvelle recherche | Portail wanayoo
iPlanet

You are here:  Home > Developers > Sample Code > Plug-in > Plug-in Sample Code
Plug-in Sample Code
 iPlanet Developers


Developer Program
  Membership
  One-to-One Support
  Newsgroups
  Member Services

Developer Publications
  View Source
  Developer News

Documentation
  Technical Manuals
  White Papers
  TechNotes
  Sample Code
  FAQs
  Books

Technologies
  Application Server   CSS
  DOM
  CORBA
  Directory & LDAP
  Dynamic HTML
  Java
  JavaScript
  Linux
  RDF
  Security
  SSJS
  XML
  XUL

Developer Downloads
  Tools & SDKs
  Patches

iPlanet Products
  Technical Resources










spacer
Implementing Hot Keys for Windows Plug-ins

Plug-in developers may can capture keystrokes to implement hot keys within their plug-in. Use the CWnd::SetFocus() if using MFC, or use SetFocus() if you are using Windows SDK.

Do the following in your Windows plug-in (Windows SDK way)
1.Call SetFocus((HWND)window->window) in your NPP_SetWindow().
2.Handle WM_KEYDOWN in your plug-in procedure.

(An extract from MFC documentation)
SetFocus() function sets the keyboard focus to the specified window.
The window, if any, that previously had the keyboard focus loses it.


Related Readings:


Any sample code included above is provided for your use on an "AS IS" basis, under the Netscape License Agreement - Terms of Use

spacer spacer


                                                       
iPlanet International | Year 2000 | Site Map | Feedback
Products | Solutions | Support | Services | Download | About Us | Developer
© 2000 Sun-Netscape Alliance. All Rights Reserved  Privacy Policy