home *** CD-ROM | disk | FTP | other *** search
- // IOBeepInspector.h
- // The Beep driver inspector and general example
- // Copyright 1993 by NeXT, Incorporated. All Rights Reserved.
-
- #import <driverkit/IODeviceInspector.h>
- #import <driverkit/IODeviceMaster.h>
-
- @interface IOBeepInspector : Object <IOConfigurationInspector>
- {
- View *beepView; // The invisible box around our controls
- Slider *frequencySlider; // Outlets to the controls
- TextField *frequencyField;
- Slider *durationSlider;
- TextField *durationField;
- Button *styleButton; // The trigger to the popup
- PopUpList *stylePopup; // We set this programatically
-
- NXStringTable *table; // Passed in during setTable:
- IODeviceMaster *devMaster; // Used to get info to/from the driver
- IOObjectNumber myTag; // Used by devMaster
- IOCharParameter durationString; // These come in handy
- IOCharParameter pitchString;
- IOCharParameter styleString;
- unsigned maxFreq; // So we don't try anything foolish...
- unsigned minFreq;
- unsigned maxDuration;
- unsigned minDuration;
- }
-
- // A couple of classics
- - init;
- - free;
-
- // These are required to conform to the IOConfigurationInspector protocol
- - setTable: (NXStringTable *)instance;
- - (View *)inspectionView;
- - resourcesChanged: (IOResources *)rsrc;
-
- // Action methods for the controls
- - frequencyDidChange: sender;
- - durationDidChange: sender;
- - styleDidChange: sender;
-
- // These are used to interact with the live driver
- - (IOReturn)getIntValue: (unsigned *)value forParameter: (IOParameterName)param;
- - (IOReturn)getStringValue: (IOCharParameter)value forParameter: (IOParameterName)param;
- - setIntValue: (unsigned *)value forParameter: (IOParameterName)param;
- - setStringValue: (IOCharParameter)value forParameter: (IOParameterName)param;
-
- @end