mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-19 01:04:20 +00:00
Minor code style tweaks.
This commit is contained in:
parent
148e9f8d25
commit
7bc8db2ff4
85 changed files with 1289 additions and 1351 deletions
|
|
@ -410,7 +410,7 @@ public:
|
|||
setImageOpacity (layout, owner, role, (float) newValue, true);
|
||||
}
|
||||
|
||||
const double getValue() const
|
||||
double getValue() const
|
||||
{
|
||||
return getImageOpacity (owner, role);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -530,7 +530,7 @@ private:
|
|||
T("Change Label font size"));
|
||||
}
|
||||
|
||||
const double getValue() const
|
||||
double getValue() const
|
||||
{
|
||||
return label->getFont().getHeight();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -496,7 +496,7 @@ private:
|
|||
element->setFont (f, true);
|
||||
}
|
||||
|
||||
const double getValue() const
|
||||
double getValue() const
|
||||
{
|
||||
return element->getFont().getHeight();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -71041,7 +71041,7 @@ void SliderPropertyComponent::setValue (const double /*newValue*/)
|
|||
{
|
||||
}
|
||||
|
||||
const double SliderPropertyComponent::getValue() const
|
||||
double SliderPropertyComponent::getValue() const
|
||||
{
|
||||
return slider->getValue();
|
||||
}
|
||||
|
|
|
|||
1315
juce_amalgamated.h
1315
juce_amalgamated.h
File diff suppressed because it is too large
Load diff
|
|
@ -222,7 +222,7 @@ public:
|
|||
*/
|
||||
virtual void unhandledException (const std::exception* e,
|
||||
const String& sourceFilename,
|
||||
const int lineNumber);
|
||||
int lineNumber);
|
||||
|
||||
//==============================================================================
|
||||
/** Signals that the main message loop should stop and the application should terminate.
|
||||
|
|
@ -248,7 +248,7 @@ public:
|
|||
|
||||
@see getApplicationReturnValue
|
||||
*/
|
||||
void setApplicationReturnValue (const int newReturnValue) throw();
|
||||
void setApplicationReturnValue (int newReturnValue) throw();
|
||||
|
||||
/** Returns the value that has been set as the application's exit code.
|
||||
@see setApplicationReturnValue
|
||||
|
|
@ -263,20 +263,20 @@ public:
|
|||
// These are used by the START_JUCE_APPLICATION() macro and aren't for public use.
|
||||
|
||||
/** @internal */
|
||||
static int main (String& commandLine, JUCEApplication* const newApp);
|
||||
static int main (String& commandLine, JUCEApplication* newApp);
|
||||
/** @internal */
|
||||
static int main (int argc, const char* argv[], JUCEApplication* const newApp);
|
||||
static int main (int argc, const char* argv[], JUCEApplication* newApp);
|
||||
|
||||
/** @internal */
|
||||
static void sendUnhandledException (const std::exception* const e,
|
||||
const char* const sourceFile,
|
||||
const int lineNumber);
|
||||
static void sendUnhandledException (const std::exception* e,
|
||||
const char* sourceFile,
|
||||
int lineNumber);
|
||||
|
||||
//==============================================================================
|
||||
/** @internal */
|
||||
ApplicationCommandTarget* getNextCommandTarget();
|
||||
/** @internal */
|
||||
void getCommandInfo (const CommandID commandID, ApplicationCommandInfo& result);
|
||||
void getCommandInfo (CommandID commandID, ApplicationCommandInfo& result);
|
||||
/** @internal */
|
||||
void getAllCommands (Array <CommandID>& commands);
|
||||
/** @internal */
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@
|
|||
struct JUCE_API ApplicationCommandInfo
|
||||
{
|
||||
//==============================================================================
|
||||
ApplicationCommandInfo (const CommandID commandID) throw();
|
||||
ApplicationCommandInfo (CommandID commandID) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Sets a number of the structures values at once.
|
||||
|
|
@ -59,18 +59,18 @@ struct JUCE_API ApplicationCommandInfo
|
|||
void setInfo (const String& shortName,
|
||||
const String& description,
|
||||
const String& categoryName,
|
||||
const int flags) throw();
|
||||
int flags) throw();
|
||||
|
||||
/** An easy way to set or remove the isDisabled bit in the structure's flags field.
|
||||
|
||||
If isActive is true, the flags member has the isDisabled bit cleared; if isActive
|
||||
is false, the bit is set.
|
||||
*/
|
||||
void setActive (const bool isActive) throw();
|
||||
void setActive (bool isActive) throw();
|
||||
|
||||
/** An easy way to set or remove the isTicked bit in the structure's flags field.
|
||||
*/
|
||||
void setTicked (const bool isTicked) throw();
|
||||
void setTicked (bool isTicked) throw();
|
||||
|
||||
/** Handy method for adding a keypress to the defaultKeypresses array.
|
||||
|
||||
|
|
@ -83,7 +83,7 @@ struct JUCE_API ApplicationCommandInfo
|
|||
myinfo.defaultKeypresses.add (KeyPress (T('s'), ModifierKeys::commandModifier));
|
||||
@endcode
|
||||
*/
|
||||
void addDefaultKeypress (const int keyCode,
|
||||
void addDefaultKeypress (int keyCode,
|
||||
const ModifierKeys& modifiers) throw();
|
||||
|
||||
//==============================================================================
|
||||
|
|
|
|||
|
|
@ -136,7 +136,7 @@ public:
|
|||
|
||||
Note that this will also remove any key mappings that are mapped to the command.
|
||||
*/
|
||||
void removeCommand (const CommandID commandID);
|
||||
void removeCommand (CommandID commandID);
|
||||
|
||||
/** This should be called to tell the manager that one of its registered commands may have changed
|
||||
its active status.
|
||||
|
|
@ -161,7 +161,7 @@ public:
|
|||
|
||||
The index is between 0 and (getNumCommands() - 1).
|
||||
*/
|
||||
const ApplicationCommandInfo* getCommandForIndex (const int index) const throw() { return commands [index]; }
|
||||
const ApplicationCommandInfo* getCommandForIndex (int index) const throw() { return commands [index]; }
|
||||
|
||||
/** Returns the details about a given command ID.
|
||||
|
||||
|
|
@ -169,14 +169,14 @@ public:
|
|||
ID number, and return its associated info. If no matching command is found, this
|
||||
will return 0.
|
||||
*/
|
||||
const ApplicationCommandInfo* getCommandForID (const CommandID commandID) const throw();
|
||||
const ApplicationCommandInfo* getCommandForID (CommandID commandID) const throw();
|
||||
|
||||
/** Returns the name field for a command.
|
||||
|
||||
An empty string is returned if no command with this ID has been registered.
|
||||
@see getDescriptionOfCommand
|
||||
*/
|
||||
const String getNameOfCommand (const CommandID commandID) const throw();
|
||||
const String getNameOfCommand (CommandID commandID) const throw();
|
||||
|
||||
/** Returns the description field for a command.
|
||||
|
||||
|
|
@ -185,7 +185,7 @@ public:
|
|||
|
||||
@see getNameOfCommand
|
||||
*/
|
||||
const String getDescriptionOfCommand (const CommandID commandID) const throw();
|
||||
const String getDescriptionOfCommand (CommandID commandID) const throw();
|
||||
|
||||
/** Returns the list of categories.
|
||||
|
||||
|
|
@ -220,8 +220,7 @@ public:
|
|||
This is just an easy way to call invoke() without having to fill out the InvocationInfo
|
||||
structure.
|
||||
*/
|
||||
bool invokeDirectly (const CommandID commandID,
|
||||
const bool asynchronously);
|
||||
bool invokeDirectly (CommandID commandID, bool asynchronously);
|
||||
|
||||
/** Sends a command to the default target.
|
||||
|
||||
|
|
@ -239,7 +238,7 @@ public:
|
|||
@see ApplicationCommandTarget::invoke
|
||||
*/
|
||||
bool invoke (const ApplicationCommandTarget::InvocationInfo& invocationInfo,
|
||||
const bool asynchronously);
|
||||
bool asynchronously);
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
@ -259,7 +258,7 @@ public:
|
|||
|
||||
@see getTargetForCommand, invoke, invokeDirectly
|
||||
*/
|
||||
virtual ApplicationCommandTarget* getFirstCommandTarget (const CommandID commandID);
|
||||
virtual ApplicationCommandTarget* getFirstCommandTarget (CommandID commandID);
|
||||
|
||||
/** Sets a target to be returned by getFirstCommandTarget().
|
||||
|
||||
|
|
@ -269,7 +268,7 @@ public:
|
|||
If you use this to set a target, make sure you call setFirstCommandTarget (0) before
|
||||
deleting the target object.
|
||||
*/
|
||||
void setFirstCommandTarget (ApplicationCommandTarget* const newTarget) throw();
|
||||
void setFirstCommandTarget (ApplicationCommandTarget* newTarget) throw();
|
||||
|
||||
/** Tries to find the best target to use to perform a given command.
|
||||
|
||||
|
|
@ -284,15 +283,15 @@ public:
|
|||
structure with the latest info about that command, so that the caller can see
|
||||
whether the command is disabled, ticked, etc.
|
||||
*/
|
||||
ApplicationCommandTarget* getTargetForCommand (const CommandID commandID,
|
||||
ApplicationCommandTarget* getTargetForCommand (CommandID commandID,
|
||||
ApplicationCommandInfo& upToDateInfo);
|
||||
|
||||
//==============================================================================
|
||||
/** Registers a listener that will be called when various events occur. */
|
||||
void addListener (ApplicationCommandManagerListener* const listener) throw();
|
||||
void addListener (ApplicationCommandManagerListener* listener) throw();
|
||||
|
||||
/** Deregisters a previously-added listener. */
|
||||
void removeListener (ApplicationCommandManagerListener* const listener) throw();
|
||||
void removeListener (ApplicationCommandManagerListener* listener) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Looks for a suitable command target based on which Components have the keyboard focus.
|
||||
|
|
|
|||
|
|
@ -81,8 +81,8 @@ public:
|
|||
void setStorageParameters (const String& applicationName,
|
||||
const String& fileNameSuffix,
|
||||
const String& folderName,
|
||||
const int millisecondsBeforeSaving,
|
||||
const int propertiesFileOptions) throw();
|
||||
int millisecondsBeforeSaving,
|
||||
int propertiesFileOptions) throw();
|
||||
|
||||
/** Tests whether the files can be successfully written to, and can show
|
||||
an error message if not.
|
||||
|
|
@ -94,9 +94,9 @@ public:
|
|||
@param showWarningDialogOnFailure if true, the method will show a helpful error
|
||||
message box if either of the tests fail
|
||||
*/
|
||||
bool testWriteAccess (const bool testUserSettings,
|
||||
const bool testCommonSettings,
|
||||
const bool showWarningDialogOnFailure);
|
||||
bool testWriteAccess (bool testUserSettings,
|
||||
bool testCommonSettings,
|
||||
bool showWarningDialogOnFailure);
|
||||
|
||||
//==============================================================================
|
||||
/** Returns the user settings file.
|
||||
|
|
@ -126,7 +126,7 @@ public:
|
|||
the common settings, even if any changes to them can't be saved.
|
||||
@see getUserSettings
|
||||
*/
|
||||
PropertiesFile* getCommonSettings (const bool returnUserPropsIfReadOnly) throw();
|
||||
PropertiesFile* getCommonSettings (bool returnUserPropsIfReadOnly) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Saves both files if they need to be saved.
|
||||
|
|
|
|||
|
|
@ -52,13 +52,13 @@ public:
|
|||
|
||||
(Trying to add a listener that's already on the list will have no effect).
|
||||
*/
|
||||
void addActionListener (ActionListener* const listener);
|
||||
void addActionListener (ActionListener* listener);
|
||||
|
||||
/** Removes a listener from the list.
|
||||
|
||||
If the listener isn't on the list, this won't have any effect.
|
||||
*/
|
||||
void removeActionListener (ActionListener* const listener);
|
||||
void removeActionListener (ActionListener* listener);
|
||||
|
||||
/** Removes all listeners from the list. */
|
||||
void removeAllActionListeners();
|
||||
|
|
|
|||
|
|
@ -56,13 +56,13 @@ public:
|
|||
|
||||
(Trying to add a listener that's already on the list will have no effect).
|
||||
*/
|
||||
void addActionListener (ActionListener* const listener) throw();
|
||||
void addActionListener (ActionListener* listener) throw();
|
||||
|
||||
/** Removes a listener from the list.
|
||||
|
||||
If the listener isn't on the list, this won't have any effect.
|
||||
*/
|
||||
void removeActionListener (ActionListener* const listener) throw();
|
||||
void removeActionListener (ActionListener* listener) throw();
|
||||
|
||||
/** Removes all listeners from the list. */
|
||||
void removeAllActionListeners() throw();
|
||||
|
|
|
|||
|
|
@ -52,13 +52,13 @@ public:
|
|||
|
||||
(Trying to add a listener that's already on the list will have no effect).
|
||||
*/
|
||||
void addChangeListener (ChangeListener* const listener) throw();
|
||||
void addChangeListener (ChangeListener* listener) throw();
|
||||
|
||||
/** Removes a listener from the list.
|
||||
|
||||
If the listener isn't on the list, this won't have any effect.
|
||||
*/
|
||||
void removeChangeListener (ChangeListener* const listener) throw();
|
||||
void removeChangeListener (ChangeListener* listener) throw();
|
||||
|
||||
/** Removes all listeners from the list. */
|
||||
void removeAllChangeListeners() throw();
|
||||
|
|
|
|||
|
|
@ -56,13 +56,13 @@ public:
|
|||
|
||||
(Trying to add a listener that's already on the list will have no effect).
|
||||
*/
|
||||
void addChangeListener (ChangeListener* const listener) throw();
|
||||
void addChangeListener (ChangeListener* listener) throw();
|
||||
|
||||
/** Removes a listener from the list.
|
||||
|
||||
If the listener isn't on the list, this won't have any effect.
|
||||
*/
|
||||
void removeChangeListener (ChangeListener* const listener) throw();
|
||||
void removeChangeListener (ChangeListener* listener) throw();
|
||||
|
||||
/** Removes all listeners from the list. */
|
||||
void removeAllChangeListeners() throw();
|
||||
|
|
|
|||
|
|
@ -73,8 +73,8 @@ public:
|
|||
can be any number, but the sender and receiver must obviously
|
||||
use matching values or they won't recognise each other.
|
||||
*/
|
||||
InterprocessConnection (const bool callbacksOnMessageThread = true,
|
||||
const uint32 magicMessageHeaderNumber = 0xf2b49e2c);
|
||||
InterprocessConnection (bool callbacksOnMessageThread = true,
|
||||
uint32 magicMessageHeaderNumber = 0xf2b49e2c);
|
||||
|
||||
/** Destructor. */
|
||||
~InterprocessConnection();
|
||||
|
|
@ -92,8 +92,8 @@ public:
|
|||
@see Socket
|
||||
*/
|
||||
bool connectToSocket (const String& hostName,
|
||||
const int portNumber,
|
||||
const int timeOutMillisecs);
|
||||
int portNumber,
|
||||
int timeOutMillisecs);
|
||||
|
||||
/** Tries to connect the object to an existing named pipe.
|
||||
|
||||
|
|
@ -107,7 +107,7 @@ public:
|
|||
@see createPipe, NamedPipe
|
||||
*/
|
||||
bool connectToPipe (const String& pipeName,
|
||||
const int pipeReceiveMessageTimeoutMs = -1);
|
||||
int pipeReceiveMessageTimeoutMs = -1);
|
||||
|
||||
/** Tries to create a new pipe for other processes to connect to.
|
||||
|
||||
|
|
@ -119,7 +119,7 @@ public:
|
|||
If another process is already using this pipe, this will fail and return false.
|
||||
*/
|
||||
bool createPipe (const String& pipeName,
|
||||
const int pipeReceiveMessageTimeoutMs = -1);
|
||||
int pipeReceiveMessageTimeoutMs = -1);
|
||||
|
||||
/** Disconnects and closes any currently-open sockets or pipes. */
|
||||
void disconnect();
|
||||
|
|
@ -197,8 +197,8 @@ private:
|
|||
//==============================================================================
|
||||
friend class InterprocessConnectionServer;
|
||||
|
||||
void initialiseWithSocket (StreamingSocket* const socket_);
|
||||
void initialiseWithPipe (NamedPipe* const pipe_);
|
||||
void initialiseWithSocket (StreamingSocket* socket_);
|
||||
void initialiseWithPipe (NamedPipe* pipe_);
|
||||
|
||||
void handleMessage (const Message& message);
|
||||
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ public:
|
|||
|
||||
@see createConnectionObject, stop
|
||||
*/
|
||||
bool beginWaitingForSocket (const int portNumber);
|
||||
bool beginWaitingForSocket (int portNumber);
|
||||
|
||||
/** Terminates the listener thread, if it's active.
|
||||
|
||||
|
|
|
|||
|
|
@ -53,10 +53,10 @@ public:
|
|||
The corresponding public member variables will be set from the parameters
|
||||
passed in.
|
||||
*/
|
||||
Message (const int intParameter1,
|
||||
const int intParameter2,
|
||||
const int intParameter3,
|
||||
void* const pointerParameter) throw();
|
||||
Message (int intParameter1,
|
||||
int intParameter2,
|
||||
int intParameter3,
|
||||
void* pointerParameter) throw();
|
||||
|
||||
/** Destructor. */
|
||||
virtual ~Message() throw();
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ public:
|
|||
references to it after calling this method.
|
||||
@see handleMessage
|
||||
*/
|
||||
void postMessage (Message* const message) const throw();
|
||||
void postMessage (Message* message) const throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Checks whether this MessageListener has been deleted.
|
||||
|
|
|
|||
|
|
@ -185,8 +185,8 @@ private:
|
|||
VoidArray modalComponents;
|
||||
static void* exitModalLoopCallback (void*);
|
||||
|
||||
void postMessageToQueue (Message* const message);
|
||||
void postCallbackMessage (Message* const message);
|
||||
void postMessageToQueue (Message* message);
|
||||
void postCallbackMessage (Message* message);
|
||||
|
||||
static void doPlatformSpecificInitialisation();
|
||||
static void doPlatformSpecificShutdown();
|
||||
|
|
@ -277,7 +277,7 @@ public:
|
|||
@endcode
|
||||
|
||||
*/
|
||||
MessageManagerLock (Thread* const threadToCheckForExitSignal = 0) throw();
|
||||
MessageManagerLock (Thread* threadToCheckForExitSignal = 0) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** This has the same behaviour as the other constructor, but takes a ThreadPoolJob
|
||||
|
|
@ -285,7 +285,7 @@ public:
|
|||
|
||||
See the MessageManagerLock (Thread*) constructor for details on how this works.
|
||||
*/
|
||||
MessageManagerLock (ThreadPoolJob* const jobToCheckForExitSignal) throw();
|
||||
MessageManagerLock (ThreadPoolJob* jobToCheckForExitSignal) throw();
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
@ -312,7 +312,7 @@ private:
|
|||
SharedEvents* sharedEvents;
|
||||
bool locked;
|
||||
|
||||
void init (Thread* const thread, ThreadPoolJob* const job) throw();
|
||||
void init (Thread* thread, ThreadPoolJob* job) throw();
|
||||
|
||||
MessageManagerLock (const MessageManagerLock&);
|
||||
MessageManagerLock& operator= (const MessageManagerLock&);
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ public:
|
|||
It's perfectly ok to call startTimer() or stopTimer() from within this
|
||||
callback to change the subsequent intervals.
|
||||
*/
|
||||
virtual void timerCallback (const int timerId) = 0;
|
||||
virtual void timerCallback (int timerId) = 0;
|
||||
|
||||
//==============================================================================
|
||||
/** Starts a timer and sets the length of interval required.
|
||||
|
|
@ -92,7 +92,7 @@ public:
|
|||
@param intervalInMilliseconds the interval to use (any values less than 1 will be
|
||||
rounded up to 1)
|
||||
*/
|
||||
void startTimer (const int timerId, const int intervalInMilliseconds) throw();
|
||||
void startTimer (int timerId, int intervalInMilliseconds) throw();
|
||||
|
||||
/** Stops a timer.
|
||||
|
||||
|
|
@ -103,21 +103,21 @@ public:
|
|||
be currently executing may be allowed to finish before the method
|
||||
returns.
|
||||
*/
|
||||
void stopTimer (const int timerId) throw();
|
||||
void stopTimer (int timerId) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Checks whether a timer has been started for a specified ID.
|
||||
|
||||
@returns true if a timer with the given ID is running.
|
||||
*/
|
||||
bool isTimerRunning (const int timerId) const throw();
|
||||
bool isTimerRunning (int timerId) const throw();
|
||||
|
||||
/** Returns the interval for a specified timer ID.
|
||||
|
||||
@returns the timer's interval in milliseconds if it's running, or 0 if it's no timer
|
||||
is running for the ID number specified.
|
||||
*/
|
||||
int getTimerInterval (const int timerId) const throw();
|
||||
int getTimerInterval (int timerId) const throw();
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ public:
|
|||
@param intervalInMilliseconds the interval to use (any values less than 1 will be
|
||||
rounded up to 1)
|
||||
*/
|
||||
void startTimer (const int intervalInMilliseconds) throw();
|
||||
void startTimer (int intervalInMilliseconds) throw();
|
||||
|
||||
/** Stops the timer.
|
||||
|
||||
|
|
|
|||
|
|
@ -129,8 +129,8 @@ public:
|
|||
be sent
|
||||
@see getToggleState, setRadioGroupId
|
||||
*/
|
||||
void setToggleState (const bool shouldBeOn,
|
||||
const bool sendChangeNotification);
|
||||
void setToggleState (bool shouldBeOn,
|
||||
bool sendChangeNotification);
|
||||
|
||||
/** Returns true if the button in 'on'.
|
||||
|
||||
|
|
@ -156,7 +156,7 @@ public:
|
|||
If set to true, then before the clicked() callback occurs, the toggle-state
|
||||
of the button is flipped.
|
||||
*/
|
||||
void setClickingTogglesState (const bool shouldToggle) throw();
|
||||
void setClickingTogglesState (bool shouldToggle) throw();
|
||||
|
||||
/** Returns true if this button is set to be an automatic toggle-button.
|
||||
|
||||
|
|
@ -182,7 +182,7 @@ public:
|
|||
|
||||
@see getRadioGroupId
|
||||
*/
|
||||
void setRadioGroupId (const int newGroupId);
|
||||
void setRadioGroupId (int newGroupId);
|
||||
|
||||
/** Returns the ID of the group to which this button belongs.
|
||||
|
||||
|
|
@ -197,13 +197,13 @@ public:
|
|||
|
||||
@see removeButtonListener
|
||||
*/
|
||||
void addButtonListener (ButtonListener* const newListener);
|
||||
void addButtonListener (ButtonListener* newListener);
|
||||
|
||||
/** Removes a previously-registered button listener
|
||||
|
||||
@see addButtonListener
|
||||
*/
|
||||
void removeButtonListener (ButtonListener* const listener);
|
||||
void removeButtonListener (ButtonListener* listener);
|
||||
|
||||
//==============================================================================
|
||||
/** Causes the button to act as if it's been clicked.
|
||||
|
|
@ -231,8 +231,8 @@ public:
|
|||
@see addShortcut, getCommandID
|
||||
*/
|
||||
void setCommandToTrigger (ApplicationCommandManager* commandManagerToUse,
|
||||
const int commandID,
|
||||
const bool generateTooltip);
|
||||
int commandID,
|
||||
bool generateTooltip);
|
||||
|
||||
/** Returns the command ID that was set by setCommandToTrigger().
|
||||
*/
|
||||
|
|
@ -276,9 +276,9 @@ public:
|
|||
get faster, the longer the button is held down, up to the
|
||||
minimum interval specified here
|
||||
*/
|
||||
void setRepeatSpeed (const int initialDelayInMillisecs,
|
||||
const int repeatDelayInMillisecs,
|
||||
const int minimumDelayInMillisecs = -1) throw();
|
||||
void setRepeatSpeed (int initialDelayInMillisecs,
|
||||
int repeatDelayInMillisecs,
|
||||
int minimumDelayInMillisecs = -1) throw();
|
||||
|
||||
/** Sets whether the button click should happen when the mouse is pressed or released.
|
||||
|
||||
|
|
@ -289,7 +289,7 @@ public:
|
|||
This is useful if the button is being used to show a pop-up menu, as it allows
|
||||
the click to be used as a drag onto the menu.
|
||||
*/
|
||||
void setTriggeredOnMouseDown (const bool isTriggeredOnMouseDown) throw();
|
||||
void setTriggeredOnMouseDown (bool isTriggeredOnMouseDown) throw();
|
||||
|
||||
/** Returns the number of milliseconds since the last time the button
|
||||
went into the 'down' state.
|
||||
|
|
@ -333,7 +333,7 @@ public:
|
|||
LookAndFeel can choose to ignore it if it's not relevent for this type of
|
||||
button.
|
||||
*/
|
||||
void setConnectedEdges (const int connectedEdgeFlags);
|
||||
void setConnectedEdges (int connectedEdgeFlags);
|
||||
|
||||
/** Returns the set of flags passed into setConnectedEdges(). */
|
||||
int getConnectedEdgeFlags() const throw() { return connectedEdgeFlags; }
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ public:
|
|||
@see ButtonStyle, setButtonStyle, setImages
|
||||
*/
|
||||
DrawableButton (const String& buttonName,
|
||||
const ButtonStyle buttonStyle);
|
||||
ButtonStyle buttonStyle);
|
||||
|
||||
/** Destructor. */
|
||||
~DrawableButton();
|
||||
|
|
@ -112,7 +112,7 @@ public:
|
|||
|
||||
@see ButtonStyle
|
||||
*/
|
||||
void setButtonStyle (const ButtonStyle newStyle);
|
||||
void setButtonStyle (ButtonStyle newStyle);
|
||||
|
||||
//==============================================================================
|
||||
/** Changes the button's background colours.
|
||||
|
|
@ -144,7 +144,7 @@ public:
|
|||
|
||||
By default there's a gap of about 3 pixels.
|
||||
*/
|
||||
void setEdgeIndent (const int numPixelsIndent);
|
||||
void setEdgeIndent (int numPixelsIndent);
|
||||
|
||||
//==============================================================================
|
||||
/** Returns the image that the button is currently displaying. */
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ public:
|
|||
to match the size of the component.
|
||||
*/
|
||||
void setFont (const Font& newFont,
|
||||
const bool resizeToMatchComponentHeight,
|
||||
bool resizeToMatchComponentHeight,
|
||||
const Justification& justificationType = Justification::horizontallyCentred);
|
||||
|
||||
//==============================================================================
|
||||
|
|
|
|||
|
|
@ -106,19 +106,19 @@ public:
|
|||
image's alpha channel at that position is greater than
|
||||
this level.
|
||||
*/
|
||||
void setImages (const bool resizeButtonNowToFitThisImage,
|
||||
const bool rescaleImagesWhenButtonSizeChanges,
|
||||
const bool preserveImageProportions,
|
||||
Image* const normalImage,
|
||||
const float imageOpacityWhenNormal,
|
||||
void setImages (bool resizeButtonNowToFitThisImage,
|
||||
bool rescaleImagesWhenButtonSizeChanges,
|
||||
bool preserveImageProportions,
|
||||
Image* normalImage,
|
||||
float imageOpacityWhenNormal,
|
||||
const Colour& overlayColourWhenNormal,
|
||||
Image* const overImage,
|
||||
const float imageOpacityWhenOver,
|
||||
Image* overImage,
|
||||
float imageOpacityWhenOver,
|
||||
const Colour& overlayColourWhenOver,
|
||||
Image* const downImage,
|
||||
const float imageOpacityWhenDown,
|
||||
Image* downImage,
|
||||
float imageOpacityWhenDown,
|
||||
const Colour& overlayColourWhenDown,
|
||||
const float hitTestAlphaThreshold = 0.0f);
|
||||
float hitTestAlphaThreshold = 0.0f);
|
||||
|
||||
/** Returns the currently set 'normal' image. */
|
||||
Image* getNormalImage() const throw();
|
||||
|
|
|
|||
|
|
@ -66,9 +66,9 @@ public:
|
|||
@param hasDropShadow if true, the button will be given a drop-shadow effect
|
||||
*/
|
||||
void setShape (const Path& newShape,
|
||||
const bool resizeNowToFitThisShape,
|
||||
const bool maintainShapeProportions,
|
||||
const bool hasDropShadow);
|
||||
bool resizeNowToFitThisShape,
|
||||
bool maintainShapeProportions,
|
||||
bool hasDropShadow);
|
||||
|
||||
/** Set the colours to use for drawing the shape.
|
||||
|
||||
|
|
@ -86,7 +86,7 @@ public:
|
|||
@param outlineStrokeWidth the thickness of line to draw
|
||||
*/
|
||||
void setOutline (const Colour& outlineColour,
|
||||
const float outlineStrokeWidth);
|
||||
float outlineStrokeWidth);
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ public:
|
|||
If newHeight is >= 0, the button's height will be changed to this
|
||||
value. If it's less than zero, its height will be unaffected.
|
||||
*/
|
||||
void changeWidthToFitText (const int newHeight = -1);
|
||||
void changeWidthToFitText (int newHeight = -1);
|
||||
|
||||
/** This can be overridden to use different fonts than the default one.
|
||||
|
||||
|
|
|
|||
|
|
@ -60,10 +60,10 @@ public:
|
|||
this object and will be deleted when no longer needed or when this button
|
||||
is deleted.
|
||||
*/
|
||||
ToolbarButton (const int itemId,
|
||||
ToolbarButton (int itemId,
|
||||
const String& labelText,
|
||||
Drawable* const normalImage,
|
||||
Drawable* const toggledOnImage);
|
||||
Drawable* normalImage,
|
||||
Drawable* toggledOnImage);
|
||||
|
||||
/** Destructor. */
|
||||
~ToolbarButton();
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ public:
|
|||
//==============================================================================
|
||||
int readNextToken (CodeDocument::Iterator& source);
|
||||
const StringArray getTokenTypes();
|
||||
const Colour getDefaultColour (const int tokenType);
|
||||
const Colour getDefaultColour (int tokenType);
|
||||
|
||||
//==============================================================================
|
||||
juce_UseDebuggingNewOperator
|
||||
|
|
|
|||
|
|
@ -82,8 +82,8 @@ public:
|
|||
Lines are numbered from zero, and if the line or index are beyond the bounds of the document,
|
||||
they will be adjusted to keep them within its limits.
|
||||
*/
|
||||
Position (const CodeDocument* const ownerDocument,
|
||||
const int line, const int indexInLine) throw();
|
||||
Position (const CodeDocument* ownerDocument,
|
||||
int line, int indexInLine) throw();
|
||||
|
||||
/** Creates a position based on a character index in a document.
|
||||
This position is placed at the specified number of characters from the start of the
|
||||
|
|
@ -92,8 +92,8 @@ public:
|
|||
If the position is beyond the range of the document, it'll be adjusted to keep it
|
||||
inside.
|
||||
*/
|
||||
Position (const CodeDocument* const ownerDocument,
|
||||
const int charactersFromStartOfDocument) throw();
|
||||
Position (const CodeDocument* ownerDocument,
|
||||
int charactersFromStartOfDocument) throw();
|
||||
|
||||
/** Creates a copy of another position.
|
||||
|
||||
|
|
@ -115,7 +115,7 @@ public:
|
|||
inside.
|
||||
@see getPosition, setLineAndIndex
|
||||
*/
|
||||
void setPosition (const int charactersFromStartOfDocument) throw();
|
||||
void setPosition (int charactersFromStartOfDocument) throw();
|
||||
|
||||
/** Returns the position as the number of characters from the start of the document.
|
||||
@see setPosition, getLineNumber, getIndexInLine
|
||||
|
|
@ -131,7 +131,7 @@ public:
|
|||
Lines are numbered from zero, and if the line or index are beyond the bounds of the document,
|
||||
they will be adjusted to keep them within its limits.
|
||||
*/
|
||||
void setLineAndIndex (const int newLine, const int newIndexInLine) throw();
|
||||
void setLineAndIndex (int newLine, int newIndexInLine) throw();
|
||||
|
||||
/** Returns the line number of this position.
|
||||
The first line in the document is numbered zero, not one!
|
||||
|
|
@ -152,7 +152,7 @@ public:
|
|||
when the document has text inserted or deleted, this position will be automatically
|
||||
moved to keep it at the same position in the text.
|
||||
*/
|
||||
void setPositionMaintained (const bool isMaintained) throw();
|
||||
void setPositionMaintained (bool isMaintained) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Moves the position forwards or backwards by the specified number of characters.
|
||||
|
|
@ -164,13 +164,13 @@ public:
|
|||
characters.
|
||||
@see moveBy
|
||||
*/
|
||||
const Position movedBy (const int characterDelta) const throw();
|
||||
const Position movedBy (int characterDelta) const throw();
|
||||
|
||||
/** Returns a position which is the same as this one, moved up or down by the specified
|
||||
number of lines.
|
||||
@see movedBy
|
||||
*/
|
||||
const Position movedByLines (const int deltaLines) const throw();
|
||||
const Position movedByLines (int deltaLines) const throw();
|
||||
|
||||
/** Returns the character in the document at this position.
|
||||
@see getLineText
|
||||
|
|
@ -197,7 +197,7 @@ public:
|
|||
const String getTextBetween (const Position& start, const Position& end) const throw();
|
||||
|
||||
/** Returns a line from the document. */
|
||||
const String getLine (const int lineIndex) const throw();
|
||||
const String getLine (int lineIndex) const throw();
|
||||
|
||||
/** Returns the number of characters in the document. */
|
||||
int getNumCharacters() const throw();
|
||||
|
|
@ -321,12 +321,12 @@ public:
|
|||
If the listener is already registered, this method has no effect.
|
||||
@see removeListener
|
||||
*/
|
||||
void addListener (Listener* const listener) throw();
|
||||
void addListener (Listener* listener) throw();
|
||||
|
||||
/** Deregisters a listener.
|
||||
@see addListener
|
||||
*/
|
||||
void removeListener (Listener* const listener) throw();
|
||||
void removeListener (Listener* listener) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Iterates the text in a CodeDocument.
|
||||
|
|
@ -339,7 +339,7 @@ public:
|
|||
class Iterator
|
||||
{
|
||||
public:
|
||||
Iterator (CodeDocument* const document);
|
||||
Iterator (CodeDocument* document);
|
||||
Iterator (const Iterator& other);
|
||||
Iterator& operator= (const Iterator& other) throw();
|
||||
~Iterator() throw();
|
||||
|
|
@ -395,10 +395,10 @@ private:
|
|||
VoidArray listeners;
|
||||
String newLineChars;
|
||||
|
||||
void sendListenerChangeMessage (const int startLine, const int endLine);
|
||||
void sendListenerChangeMessage (int startLine, int endLine);
|
||||
|
||||
void insert (const String& text, const int insertPos, const bool undoable);
|
||||
void remove (const int startPos, const int endPos, const bool undoable);
|
||||
void insert (const String& text, int insertPos, bool undoable);
|
||||
void remove (int startPos, int endPos, bool undoable);
|
||||
void checkLastLineStatus();
|
||||
|
||||
CodeDocument (const CodeDocument&);
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ public:
|
|||
@see CodeDocument
|
||||
*/
|
||||
CodeEditorComponent (CodeDocument& document,
|
||||
CodeTokeniser* const codeTokeniser);
|
||||
CodeTokeniser* codeTokeniser);
|
||||
|
||||
/** Destructor. */
|
||||
~CodeEditorComponent();
|
||||
|
|
@ -99,7 +99,7 @@ public:
|
|||
caret position and the new one will become selected. If false, any currently
|
||||
selected region will be deselected.
|
||||
*/
|
||||
void moveCaretTo (const CodeDocument::Position& newPos, const bool selecting);
|
||||
void moveCaretTo (const CodeDocument::Position& newPos, bool selecting);
|
||||
|
||||
/** Returns the on-screen position of a character in the document.
|
||||
The rectangle returned is relative to this component's top-left origin.
|
||||
|
|
@ -112,13 +112,13 @@ public:
|
|||
const CodeDocument::Position getPositionAt (int x, int y);
|
||||
|
||||
//==============================================================================
|
||||
void cursorLeft (const bool moveInWholeWordSteps, const bool selecting);
|
||||
void cursorRight (const bool moveInWholeWordSteps, const bool selecting);
|
||||
void cursorDown (const bool selecting);
|
||||
void cursorUp (const bool selecting);
|
||||
void cursorLeft (bool moveInWholeWordSteps, bool selecting);
|
||||
void cursorRight (bool moveInWholeWordSteps, bool selecting);
|
||||
void cursorDown (bool selecting);
|
||||
void cursorUp (bool selecting);
|
||||
|
||||
void pageDown (const bool selecting);
|
||||
void pageUp (const bool selecting);
|
||||
void pageDown (bool selecting);
|
||||
void pageUp (bool selecting);
|
||||
|
||||
void scrollDown();
|
||||
void scrollUp();
|
||||
|
|
@ -127,10 +127,10 @@ public:
|
|||
void scrollToColumn (int newFirstColumnOnScreen);
|
||||
void scrollToKeepCaretOnScreen();
|
||||
|
||||
void goToStartOfDocument (const bool selecting);
|
||||
void goToStartOfLine (const bool selecting);
|
||||
void goToEndOfDocument (const bool selecting);
|
||||
void goToEndOfLine (const bool selecting);
|
||||
void goToStartOfDocument (bool selecting);
|
||||
void goToStartOfLine (bool selecting);
|
||||
void goToEndOfDocument (bool selecting);
|
||||
void goToEndOfLine (bool selecting);
|
||||
|
||||
void deselectAll();
|
||||
void selectAll();
|
||||
|
|
@ -141,8 +141,8 @@ public:
|
|||
void copy();
|
||||
void copyThenCut();
|
||||
void paste();
|
||||
void backspace (const bool moveInWholeWordSteps);
|
||||
void deleteForward (const bool moveInWholeWordSteps);
|
||||
void backspace (bool moveInWholeWordSteps);
|
||||
void deleteForward (bool moveInWholeWordSteps);
|
||||
|
||||
void undo();
|
||||
void redo();
|
||||
|
|
@ -157,8 +157,8 @@ public:
|
|||
This lets you change the tab size and whether pressing the tab key inserts a
|
||||
tab character, or its equivalent number of spaces.
|
||||
*/
|
||||
void setTabSize (const int numSpacesPerTab,
|
||||
const bool insertSpacesInsteadOfTabCharacters) throw();
|
||||
void setTabSize (int numSpacesPerTab,
|
||||
bool insertSpacesInsteadOfTabCharacters) throw();
|
||||
|
||||
/** Returns the current number of spaces per tab.
|
||||
@see setTabSize
|
||||
|
|
@ -186,14 +186,14 @@ public:
|
|||
CodeTokeniser::getTokenTypes() to get a list of the token types.
|
||||
@see getColourForTokenType
|
||||
*/
|
||||
void setColourForTokenType (const int tokenType, const Colour& colour);
|
||||
void setColourForTokenType (int tokenType, const Colour& colour);
|
||||
|
||||
/** Returns one of the syntax highlighting colours.
|
||||
The token type values are dependent on the tokeniser being used - use
|
||||
CodeTokeniser::getTokenTypes() to get a list of the token types.
|
||||
@see setColourForTokenType
|
||||
*/
|
||||
const Colour getColourForTokenType (const int tokenType) const throw();
|
||||
const Colour getColourForTokenType (int tokenType) const throw();
|
||||
|
||||
//==============================================================================
|
||||
/** A set of colour IDs to use to change the colour of various aspects of the editor.
|
||||
|
|
@ -215,7 +215,7 @@ public:
|
|||
|
||||
//==============================================================================
|
||||
/** Changes the size of the scrollbars. */
|
||||
void setScrollbarThickness (const int thickness) throw();
|
||||
void setScrollbarThickness (int thickness) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** @internal */
|
||||
|
|
@ -282,10 +282,10 @@ private:
|
|||
void rebuildLineTokens();
|
||||
|
||||
OwnedArray <CodeDocument::Iterator> cachedIterators;
|
||||
void clearCachedIterators (const int firstLineToBeInvalid) throw();
|
||||
void clearCachedIterators (int firstLineToBeInvalid) throw();
|
||||
void updateCachedIterators (int maxLineNum);
|
||||
void getIteratorForPosition (int position, CodeDocument::Iterator& result);
|
||||
void moveLineDelta (const int delta, const bool selecting);
|
||||
void moveLineDelta (int delta, bool selecting);
|
||||
|
||||
//==============================================================================
|
||||
void updateScrollBars();
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ public:
|
|||
/** Returns a suggested syntax highlighting colour for a specified
|
||||
token type.
|
||||
*/
|
||||
virtual const Colour getDefaultColour (const int tokenType) = 0;
|
||||
virtual const Colour getDefaultColour (int tokenType) = 0;
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ public:
|
|||
The default state for a new ComboBox is non-editable, and can only be changed
|
||||
by choosing from the drop-down list.
|
||||
*/
|
||||
void setEditableText (const bool isEditable);
|
||||
void setEditableText (bool isEditable);
|
||||
|
||||
/** Returns true if the text is directly editable.
|
||||
@see setEditableText
|
||||
|
|
@ -123,7 +123,7 @@ public:
|
|||
@see setItemEnabled, addSeparator, addSectionHeading, removeItem, getNumItems, getItemText, getItemId
|
||||
*/
|
||||
void addItem (const String& newItemText,
|
||||
const int newItemId) throw();
|
||||
int newItemId) throw();
|
||||
|
||||
/** Adds a separator line to the drop-down list.
|
||||
|
||||
|
|
@ -150,12 +150,12 @@ public:
|
|||
If you disable an item which is already selected, this won't change the
|
||||
current selection - it just stops the user choosing that item from the list.
|
||||
*/
|
||||
void setItemEnabled (const int itemId,
|
||||
const bool shouldBeEnabled) throw();
|
||||
void setItemEnabled (int itemId,
|
||||
bool shouldBeEnabled) throw();
|
||||
|
||||
/** Changes the text for an existing item.
|
||||
*/
|
||||
void changeItemText (const int itemId,
|
||||
void changeItemText (int itemId,
|
||||
const String& newText) throw();
|
||||
|
||||
/** Removes all the items from the drop-down list.
|
||||
|
|
@ -165,7 +165,7 @@ public:
|
|||
|
||||
@see addItem, removeItem, getNumItems
|
||||
*/
|
||||
void clear (const bool dontSendChangeMessage = false);
|
||||
void clear (bool dontSendChangeMessage = false);
|
||||
|
||||
/** Returns the number of items that have been added to the list.
|
||||
|
||||
|
|
@ -179,7 +179,7 @@ public:
|
|||
|
||||
@param index the item's index from 0 to (getNumItems() - 1)
|
||||
*/
|
||||
const String getItemText (const int index) const throw();
|
||||
const String getItemText (int index) const throw();
|
||||
|
||||
/** Returns the ID for one of the items in the list.
|
||||
|
||||
|
|
@ -187,12 +187,12 @@ public:
|
|||
|
||||
@param index the item's index from 0 to (getNumItems() - 1)
|
||||
*/
|
||||
int getItemId (const int index) const throw();
|
||||
int getItemId (int index) const throw();
|
||||
|
||||
/** Returns the index in the list of a particular item ID.
|
||||
If no such ID is found, this will return -1.
|
||||
*/
|
||||
int indexOfItemId (const int itemId) const throw();
|
||||
int indexOfItemId (int itemId) const throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Returns the ID of the item that's currently shown in the box.
|
||||
|
|
@ -222,8 +222,8 @@ public:
|
|||
change notification
|
||||
@see getSelectedId, setSelectedItemIndex, setText
|
||||
*/
|
||||
void setSelectedId (const int newItemId,
|
||||
const bool dontSendChangeMessage = false) throw();
|
||||
void setSelectedId (int newItemId,
|
||||
bool dontSendChangeMessage = false) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Returns the index of the item that's currently shown in the box.
|
||||
|
|
@ -246,8 +246,8 @@ public:
|
|||
change notification
|
||||
@see getSelectedItemIndex, setSelectedId, setText
|
||||
*/
|
||||
void setSelectedItemIndex (const int newItemIndex,
|
||||
const bool dontSendChangeMessage = false) throw();
|
||||
void setSelectedItemIndex (int newItemIndex,
|
||||
bool dontSendChangeMessage = false) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Returns the text that is currently shown in the combo-box's text field.
|
||||
|
|
@ -273,7 +273,7 @@ public:
|
|||
@see getText
|
||||
*/
|
||||
void setText (const String& newText,
|
||||
const bool dontSendChangeMessage = false) throw();
|
||||
bool dontSendChangeMessage = false) throw();
|
||||
|
||||
/** Programmatically opens the text editor to allow the user to edit the current item.
|
||||
|
||||
|
|
@ -284,10 +284,10 @@ public:
|
|||
|
||||
//==============================================================================
|
||||
/** Registers a listener that will be called when the box's content changes. */
|
||||
void addListener (ComboBoxListener* const listener) throw();
|
||||
void addListener (ComboBoxListener* listener) throw();
|
||||
|
||||
/** Deregisters a previously-registered listener. */
|
||||
void removeListener (ComboBoxListener* const listener) throw();
|
||||
void removeListener (ComboBoxListener* listener) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Sets a message to display when there is no item currently selected.
|
||||
|
|
@ -368,7 +368,7 @@ public:
|
|||
/** @internal */
|
||||
void resized();
|
||||
/** @internal */
|
||||
bool keyStateChanged (const bool isKeyDown);
|
||||
bool keyStateChanged (bool isKeyDown);
|
||||
/** @internal */
|
||||
bool keyPressed (const KeyPress&);
|
||||
/** @internal */
|
||||
|
|
@ -398,8 +398,8 @@ private:
|
|||
|
||||
void showPopup();
|
||||
|
||||
ItemInfo* getItemForId (const int itemId) const throw();
|
||||
ItemInfo* getItemForIndex (const int index) const throw();
|
||||
ItemInfo* getItemForId (int itemId) const throw();
|
||||
ItemInfo* getItemForIndex (int index) const throw();
|
||||
|
||||
ComboBox (const ComboBox&);
|
||||
ComboBox& operator= (const ComboBox&);
|
||||
|
|
|
|||
|
|
@ -85,7 +85,7 @@ public:
|
|||
are registered.
|
||||
*/
|
||||
void setText (const String& newText,
|
||||
const bool broadcastChangeMessage);
|
||||
bool broadcastChangeMessage);
|
||||
|
||||
/** Returns the label's current text.
|
||||
|
||||
|
|
@ -96,7 +96,7 @@ public:
|
|||
the user has finished typing and pressed the return
|
||||
key.
|
||||
*/
|
||||
const String getText (const bool returnActiveEditorContents = false) const throw();
|
||||
const String getText (bool returnActiveEditorContents = false) const throw();
|
||||
|
||||
/** Returns the text content as a Value object.
|
||||
You can call Value::referTo() on this object to make the label read and control
|
||||
|
|
@ -169,8 +169,7 @@ public:
|
|||
@param onLeft if true, the label will stay on the left of its component; if
|
||||
false, it will stay above it.
|
||||
*/
|
||||
void attachToComponent (Component* owner,
|
||||
const bool onLeft);
|
||||
void attachToComponent (Component* owner, bool onLeft);
|
||||
|
||||
/** If this label has been attached to another component using attachToComponent, this
|
||||
returns the other component.
|
||||
|
|
@ -191,16 +190,16 @@ public:
|
|||
|
||||
@see Graphics::drawFittedText
|
||||
*/
|
||||
void setMinimumHorizontalScale (const float newScale);
|
||||
void setMinimumHorizontalScale (float newScale);
|
||||
|
||||
float getMinimumHorizontalScale() const throw() { return minimumHorizontalScale; }
|
||||
|
||||
//==============================================================================
|
||||
/** Registers a listener that will be called when the label's text changes. */
|
||||
void addListener (LabelListener* const listener) throw();
|
||||
void addListener (LabelListener* listener) throw();
|
||||
|
||||
/** Deregisters a previously-registered listener. */
|
||||
void removeListener (LabelListener* const listener) throw();
|
||||
void removeListener (LabelListener* listener) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Makes the label turn into a TextEditor when clicked.
|
||||
|
|
@ -223,9 +222,9 @@ public:
|
|||
commit the changes.
|
||||
@see showEditor, setEditorColours, TextEditor
|
||||
*/
|
||||
void setEditable (const bool editOnSingleClick,
|
||||
const bool editOnDoubleClick = false,
|
||||
const bool lossOfFocusDiscardsChanges = false) throw();
|
||||
void setEditable (bool editOnSingleClick,
|
||||
bool editOnDoubleClick = false,
|
||||
bool lossOfFocusDiscardsChanges = false) throw();
|
||||
|
||||
/** Returns true if this option was set using setEditable(). */
|
||||
bool isEditableOnSingleClick() const throw() { return editSingleClick; }
|
||||
|
|
@ -253,7 +252,7 @@ public:
|
|||
editor will be used to set the label's text
|
||||
before it is hidden.
|
||||
*/
|
||||
void hideEditor (const bool discardCurrentEditorContents);
|
||||
void hideEditor (bool discardCurrentEditorContents);
|
||||
|
||||
/** Returns true if the editor is currently focused and active. */
|
||||
bool isBeingEdited() const throw();
|
||||
|
|
|
|||
|
|
@ -176,7 +176,7 @@ public:
|
|||
with setModel().
|
||||
*/
|
||||
ListBox (const String& componentName,
|
||||
ListBoxModel* const model);
|
||||
ListBoxModel* model);
|
||||
|
||||
/** Destructor. */
|
||||
~ListBox();
|
||||
|
|
@ -184,7 +184,7 @@ public:
|
|||
|
||||
//==============================================================================
|
||||
/** Changes the current data model to display. */
|
||||
void setModel (ListBoxModel* const newModel);
|
||||
void setModel (ListBoxModel* newModel);
|
||||
|
||||
/** Returns the current list model. */
|
||||
ListBoxModel* getModel() const throw() { return model; }
|
||||
|
|
@ -234,7 +234,7 @@ public:
|
|||
@see isRowSelected, selectRowsBasedOnModifierKeys, flipRowSelection, deselectRow,
|
||||
deselectAllRows, selectRangeOfRows
|
||||
*/
|
||||
void selectRow (const int rowNumber,
|
||||
void selectRow (int rowNumber,
|
||||
bool dontScrollToShowThisRow = false,
|
||||
bool deselectOthersFirst = true);
|
||||
|
||||
|
|
@ -255,7 +255,7 @@ public:
|
|||
|
||||
@see selectRow, deselectAllRows
|
||||
*/
|
||||
void deselectRow (const int rowNumber);
|
||||
void deselectRow (int rowNumber);
|
||||
|
||||
/** Deselects any currently selected rows.
|
||||
|
||||
|
|
@ -267,7 +267,7 @@ public:
|
|||
|
||||
If the row's currently selected, this deselects it, and vice-versa.
|
||||
*/
|
||||
void flipRowSelection (const int rowNumber);
|
||||
void flipRowSelection (int rowNumber);
|
||||
|
||||
/** Returns a sparse set indicating the rows that are currently selected.
|
||||
|
||||
|
|
@ -283,11 +283,11 @@ public:
|
|||
@see getSelectedRows
|
||||
*/
|
||||
void setSelectedRows (const SparseSet<int>& setOfRowsToBeSelected,
|
||||
const bool sendNotificationEventToModel = true);
|
||||
bool sendNotificationEventToModel = true);
|
||||
|
||||
/** Checks whether a row is selected.
|
||||
*/
|
||||
bool isRowSelected (const int rowNumber) const;
|
||||
bool isRowSelected (int rowNumber) const;
|
||||
|
||||
/** Returns the number of rows that are currently selected.
|
||||
|
||||
|
|
@ -305,7 +305,7 @@ public:
|
|||
selected
|
||||
@see getNumSelectedRows, isRowSelected, getLastRowSelected
|
||||
*/
|
||||
int getSelectedRow (const int index = 0) const;
|
||||
int getSelectedRow (int index = 0) const;
|
||||
|
||||
/** Returns the last row that the user selected.
|
||||
|
||||
|
|
@ -329,7 +329,7 @@ public:
|
|||
|
||||
@see selectRow
|
||||
*/
|
||||
void selectRowsBasedOnModifierKeys (const int rowThatWasClickedOn,
|
||||
void selectRowsBasedOnModifierKeys (int rowThatWasClickedOn,
|
||||
const ModifierKeys& modifiers);
|
||||
|
||||
//==============================================================================
|
||||
|
|
@ -343,7 +343,7 @@ public:
|
|||
|
||||
@see getVerticalPosition
|
||||
*/
|
||||
void setVerticalPosition (const double newProportion);
|
||||
void setVerticalPosition (double newProportion);
|
||||
|
||||
/** Returns the current vertical position as a proportion of the total.
|
||||
|
||||
|
|
@ -356,7 +356,7 @@ public:
|
|||
|
||||
/** Scrolls if necessary to make sure that a particular row is visible.
|
||||
*/
|
||||
void scrollToEnsureRowIsOnscreen (const int row);
|
||||
void scrollToEnsureRowIsOnscreen (int row);
|
||||
|
||||
/** Returns a pointer to the scrollbar.
|
||||
|
||||
|
|
@ -378,7 +378,7 @@ public:
|
|||
|
||||
@see getComponentForRowNumber
|
||||
*/
|
||||
int getRowContainingPosition (const int x, const int y) const throw();
|
||||
int getRowContainingPosition (int x, int y) const throw();
|
||||
|
||||
/** Finds a row index that would be the most suitable place to insert a new
|
||||
item for a given position.
|
||||
|
|
@ -393,7 +393,7 @@ public:
|
|||
|
||||
@see getComponentForRowNumber
|
||||
*/
|
||||
int getInsertionIndexForPosition (const int x, const int y) const throw();
|
||||
int getInsertionIndexForPosition (int x, int y) const throw();
|
||||
|
||||
/** Returns the position of one of the rows, relative to the top-left of
|
||||
the listbox.
|
||||
|
|
@ -401,8 +401,8 @@ public:
|
|||
This may be off-screen, and the range of the row number that is passed-in is
|
||||
not checked to see if it's a valid row.
|
||||
*/
|
||||
const Rectangle<int> getRowPosition (const int rowNumber,
|
||||
const bool relativeToComponentTopLeft) const throw();
|
||||
const Rectangle<int> getRowPosition (int rowNumber,
|
||||
bool relativeToComponentTopLeft) const throw();
|
||||
|
||||
/** Finds the row component for a given row in the list.
|
||||
|
||||
|
|
@ -413,13 +413,13 @@ public:
|
|||
|
||||
@see getRowContainingPosition
|
||||
*/
|
||||
Component* getComponentForRowNumber (const int rowNumber) const throw();
|
||||
Component* getComponentForRowNumber (int rowNumber) const throw();
|
||||
|
||||
/** Returns the row number that the given component represents.
|
||||
|
||||
If the component isn't one of the list's rows, this will return -1.
|
||||
*/
|
||||
int getRowNumberOfComponent (Component* const rowComponent) const throw();
|
||||
int getRowNumberOfComponent (Component* rowComponent) const throw();
|
||||
|
||||
/** Returns the width of a row (which may be less than the width of this component
|
||||
if there's a scrollbar).
|
||||
|
|
@ -433,7 +433,7 @@ public:
|
|||
|
||||
@see getRowHeight
|
||||
*/
|
||||
void setRowHeight (const int newHeight);
|
||||
void setRowHeight (int newHeight);
|
||||
|
||||
/** Returns the height of a row in the list.
|
||||
|
||||
|
|
@ -470,7 +470,7 @@ public:
|
|||
To set the colour of the outline, use @code setColour (ListBox::outlineColourId, colourXYZ); @endcode
|
||||
@see outlineColourId
|
||||
*/
|
||||
void setOutlineThickness (const int outlineThickness);
|
||||
void setOutlineThickness (int outlineThickness);
|
||||
|
||||
/** Returns the thickness of outline that will be drawn around the listbox.
|
||||
|
||||
|
|
@ -487,7 +487,7 @@ public:
|
|||
The component will be deleted when setHeaderComponent() is called with a
|
||||
different component, or when the listbox is deleted.
|
||||
*/
|
||||
void setHeaderComponent (Component* const newHeaderComponent);
|
||||
void setHeaderComponent (Component* newHeaderComponent);
|
||||
|
||||
/** Changes the width of the rows in the list.
|
||||
|
||||
|
|
@ -499,7 +499,7 @@ public:
|
|||
The default value for this is 0, which means that the rows will always
|
||||
be the same width as the list.
|
||||
*/
|
||||
void setMinimumContentWidth (const int newMinimumWidth);
|
||||
void setMinimumContentWidth (int newMinimumWidth);
|
||||
|
||||
/** Returns the space currently available for the row items, taking into account
|
||||
borders, scrollbars, etc.
|
||||
|
|
@ -511,7 +511,7 @@ public:
|
|||
This is a lightweight alternative to calling updateContent, and just causes a
|
||||
repaint of the row's area.
|
||||
*/
|
||||
void repaintRow (const int rowNumber) throw();
|
||||
void repaintRow (int rowNumber) throw();
|
||||
|
||||
/** This fairly obscure method creates an image that just shows the currently
|
||||
selected row components.
|
||||
|
|
@ -539,7 +539,7 @@ public:
|
|||
/** @internal */
|
||||
bool keyPressed (const KeyPress& key);
|
||||
/** @internal */
|
||||
bool keyStateChanged (const bool isKeyDown);
|
||||
bool keyStateChanged (bool isKeyDown);
|
||||
/** @internal */
|
||||
void paint (Graphics& g);
|
||||
/** @internal */
|
||||
|
|
@ -576,7 +576,7 @@ private:
|
|||
bool mouseMoveSelects, multipleSelection, hasDoneInitialUpdate;
|
||||
SparseSet <int> selected;
|
||||
|
||||
void selectRowInternal (const int rowNumber,
|
||||
void selectRowInternal (int rowNumber,
|
||||
bool dontScrollToShowThisRow,
|
||||
bool deselectOthersFirst,
|
||||
bool isMouseClick);
|
||||
|
|
|
|||
|
|
@ -109,7 +109,7 @@ public:
|
|||
@param newStyle the type of interface
|
||||
@see setRotaryParameters, setVelocityBasedMode,
|
||||
*/
|
||||
void setSliderStyle (const SliderStyle newStyle);
|
||||
void setSliderStyle (SliderStyle newStyle);
|
||||
|
||||
/** Returns the slider's current style.
|
||||
|
||||
|
|
@ -129,9 +129,9 @@ public:
|
|||
minimum or maximum, it'll stop there; if false, it'll wrap
|
||||
back to the opposite value
|
||||
*/
|
||||
void setRotaryParameters (const float startAngleRadians,
|
||||
const float endAngleRadians,
|
||||
const bool stopAtEnd);
|
||||
void setRotaryParameters (float startAngleRadians,
|
||||
float endAngleRadians,
|
||||
bool stopAtEnd);
|
||||
|
||||
/** Sets the distance the mouse has to move to drag the slider across
|
||||
the full extent of its range.
|
||||
|
|
@ -139,7 +139,7 @@ public:
|
|||
This only applies when in modes like RotaryHorizontalDrag, where it's using
|
||||
relative mouse movements to adjust the slider.
|
||||
*/
|
||||
void setMouseDragSensitivity (const int distanceForFullScaleDrag);
|
||||
void setMouseDragSensitivity (int distanceForFullScaleDrag);
|
||||
|
||||
//==============================================================================
|
||||
/** Changes the way the the mouse is used when dragging the slider.
|
||||
|
|
@ -150,7 +150,7 @@ public:
|
|||
|
||||
If false, the slider will just try to snap to wherever the mouse is.
|
||||
*/
|
||||
void setVelocityBasedMode (const bool isVelocityBased);
|
||||
void setVelocityBasedMode (bool isVelocityBased);
|
||||
|
||||
/** Returns true if velocity-based mode is active.
|
||||
@see setVelocityBasedMode
|
||||
|
|
@ -170,10 +170,10 @@ public:
|
|||
@param userCanPressKeyToSwapMode if true, then the user can hold down the ctrl or command
|
||||
key to toggle velocity-sensitive mode
|
||||
*/
|
||||
void setVelocityModeParameters (const double sensitivity = 1.0,
|
||||
const int threshold = 1,
|
||||
const double offset = 0.0,
|
||||
const bool userCanPressKeyToSwapMode = true);
|
||||
void setVelocityModeParameters (double sensitivity = 1.0,
|
||||
int threshold = 1,
|
||||
double offset = 0.0,
|
||||
bool userCanPressKeyToSwapMode = true);
|
||||
|
||||
/** Returns the velocity sensitivity setting.
|
||||
@see setVelocityModeParameters
|
||||
|
|
@ -211,7 +211,7 @@ public:
|
|||
|
||||
@see getSkewFactor, setSkewFactorFromMidPoint
|
||||
*/
|
||||
void setSkewFactor (const double factor);
|
||||
void setSkewFactor (double factor);
|
||||
|
||||
/** Sets up a skew factor to alter the way values are distributed.
|
||||
|
||||
|
|
@ -220,7 +220,7 @@ public:
|
|||
|
||||
@see setSkewFactor, getSkewFactor
|
||||
*/
|
||||
void setSkewFactorFromMidPoint (const double sliderValueToShowAtMidPoint);
|
||||
void setSkewFactorFromMidPoint (double sliderValueToShowAtMidPoint);
|
||||
|
||||
/** Returns the current skew factor.
|
||||
|
||||
|
|
@ -251,7 +251,7 @@ public:
|
|||
incDecButtonsDraggable_AutoDirection so that it depends on whether the buttons
|
||||
are side-by-side or above each other.
|
||||
*/
|
||||
void setIncDecButtonsMode (const IncDecButtonMode mode);
|
||||
void setIncDecButtonsMode (IncDecButtonMode mode);
|
||||
|
||||
//==============================================================================
|
||||
/** The position of the slider's text-entry box.
|
||||
|
|
@ -278,10 +278,10 @@ public:
|
|||
|
||||
@see setTextBoxIsEditable, getValueFromText, getTextFromValue
|
||||
*/
|
||||
void setTextBoxStyle (const TextEntryBoxPosition newPosition,
|
||||
const bool isReadOnly,
|
||||
const int textEntryBoxWidth,
|
||||
const int textEntryBoxHeight);
|
||||
void setTextBoxStyle (TextEntryBoxPosition newPosition,
|
||||
bool isReadOnly,
|
||||
int textEntryBoxWidth,
|
||||
int textEntryBoxHeight);
|
||||
|
||||
/** Returns the status of the text-box.
|
||||
@see setTextBoxStyle
|
||||
|
|
@ -305,7 +305,7 @@ public:
|
|||
|
||||
@see setTextBoxStyle, getValueFromText, getTextFromValue
|
||||
*/
|
||||
void setTextBoxIsEditable (const bool shouldBeEditable);
|
||||
void setTextBoxIsEditable (bool shouldBeEditable);
|
||||
|
||||
/** Returns true if the text-box is read-only.
|
||||
@see setTextBoxStyle
|
||||
|
|
@ -327,7 +327,7 @@ public:
|
|||
text editor will be used to set the slider position
|
||||
before it is hidden.
|
||||
*/
|
||||
void hideTextBox (const bool discardCurrentEditorContents);
|
||||
void hideTextBox (bool discardCurrentEditorContents);
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
@ -346,8 +346,8 @@ public:
|
|||
synchronously; if false, it will be asynchronous
|
||||
*/
|
||||
void setValue (double newValue,
|
||||
const bool sendUpdateMessage = true,
|
||||
const bool sendMessageSynchronously = false);
|
||||
bool sendUpdateMessage = true,
|
||||
bool sendMessageSynchronously = false);
|
||||
|
||||
/** Returns the slider's current value. */
|
||||
double getValue() const;
|
||||
|
|
@ -368,9 +368,9 @@ public:
|
|||
@param newInterval the steps in which the value is allowed to increase - if this
|
||||
is not zero, the value will always be (newMinimum + (newInterval * an integer)).
|
||||
*/
|
||||
void setRange (const double newMinimum,
|
||||
const double newMaximum,
|
||||
const double newInterval = 0);
|
||||
void setRange (double newMinimum,
|
||||
double newMaximum,
|
||||
double newInterval = 0);
|
||||
|
||||
/** Returns the current maximum value.
|
||||
@see setRange
|
||||
|
|
@ -426,9 +426,9 @@ public:
|
|||
@see getMinValue, setMaxValue, setValue
|
||||
*/
|
||||
void setMinValue (double newValue,
|
||||
const bool sendUpdateMessage = true,
|
||||
const bool sendMessageSynchronously = false,
|
||||
const bool allowNudgingOfOtherValues = false);
|
||||
bool sendUpdateMessage = true,
|
||||
bool sendMessageSynchronously = false,
|
||||
bool allowNudgingOfOtherValues = false);
|
||||
|
||||
/** For a slider with two or three thumbs, this returns the higher of its values.
|
||||
|
||||
|
|
@ -468,16 +468,16 @@ public:
|
|||
@see getMaxValue, setMinValue, setValue
|
||||
*/
|
||||
void setMaxValue (double newValue,
|
||||
const bool sendUpdateMessage = true,
|
||||
const bool sendMessageSynchronously = false,
|
||||
const bool allowNudgingOfOtherValues = false);
|
||||
bool sendUpdateMessage = true,
|
||||
bool sendMessageSynchronously = false,
|
||||
bool allowNudgingOfOtherValues = false);
|
||||
|
||||
//==============================================================================
|
||||
/** Adds a listener to be called when this slider's value changes. */
|
||||
void addListener (SliderListener* const listener);
|
||||
void addListener (SliderListener* listener);
|
||||
|
||||
/** Removes a previously-registered listener. */
|
||||
void removeListener (SliderListener* const listener);
|
||||
void removeListener (SliderListener* listener);
|
||||
|
||||
//==============================================================================
|
||||
/** This lets you choose whether double-clicking moves the slider to a given position.
|
||||
|
|
@ -488,8 +488,8 @@ public:
|
|||
|
||||
@see getDoubleClickReturnValue
|
||||
*/
|
||||
void setDoubleClickReturnValue (const bool isDoubleClickEnabled,
|
||||
const double valueToSetOnDoubleClick);
|
||||
void setDoubleClickReturnValue (bool isDoubleClickEnabled,
|
||||
double valueToSetOnDoubleClick);
|
||||
|
||||
/** Returns the values last set by setDoubleClickReturnValue() method.
|
||||
|
||||
|
|
@ -509,7 +509,7 @@ public:
|
|||
will be continuously sent as they drag it while the mouse button is still
|
||||
held down.
|
||||
*/
|
||||
void setChangeNotificationOnlyOnRelease (const bool onlyNotifyOnRelease);
|
||||
void setChangeNotificationOnlyOnRelease (bool onlyNotifyOnRelease);
|
||||
|
||||
/** This lets you change whether the slider thumb jumps to the mouse position
|
||||
when you click.
|
||||
|
|
@ -520,7 +520,7 @@ public:
|
|||
This only applies to linear bars, and won't affect two- or three- value
|
||||
sliders.
|
||||
*/
|
||||
void setSliderSnapsToMousePosition (const bool shouldSnapToMouse);
|
||||
void setSliderSnapsToMousePosition (bool shouldSnapToMouse);
|
||||
|
||||
/** If enabled, this gives the slider a pop-up bubble which appears while the
|
||||
slider is being dragged.
|
||||
|
|
@ -534,8 +534,8 @@ public:
|
|||
transparent window, so if you're using an OS that can't do transparent windows
|
||||
you'll have to add it to a parent component instead).
|
||||
*/
|
||||
void setPopupDisplayEnabled (const bool isEnabled,
|
||||
Component* const parentComponentToUse);
|
||||
void setPopupDisplayEnabled (bool isEnabled,
|
||||
Component* parentComponentToUse);
|
||||
|
||||
/** If this is set to true, then right-clicking on the slider will pop-up
|
||||
a menu to let the user change the way it works.
|
||||
|
|
@ -544,13 +544,13 @@ public:
|
|||
things like velocity sensitivity, and for rotary sliders, whether they
|
||||
use a linear or rotary mouse-drag to move them.
|
||||
*/
|
||||
void setPopupMenuEnabled (const bool menuEnabled);
|
||||
void setPopupMenuEnabled (bool menuEnabled);
|
||||
|
||||
/** This can be used to stop the mouse scroll-wheel from moving the slider.
|
||||
|
||||
By default it's enabled.
|
||||
*/
|
||||
void setScrollWheelEnabled (const bool enabled);
|
||||
void setScrollWheelEnabled (bool enabled);
|
||||
|
||||
/** Returns a number to indicate which thumb is currently being dragged by the
|
||||
mouse.
|
||||
|
|
@ -658,7 +658,7 @@ public:
|
|||
If the slider is rotary, this will throw an assertion and return 0. If the
|
||||
value is out-of-range, it will be constrained to the length of the slider.
|
||||
*/
|
||||
float getPositionOfValue (const double value);
|
||||
float getPositionOfValue (double value);
|
||||
|
||||
//==============================================================================
|
||||
/** This can be overridden to allow the slider to snap to user-definable values.
|
||||
|
|
@ -672,7 +672,7 @@ public:
|
|||
they are entering the value using the text box
|
||||
@returns the value to use instead
|
||||
*/
|
||||
virtual double snapValue (double attemptedValue, const bool userIsDragging);
|
||||
virtual double snapValue (double attemptedValue, bool userIsDragging);
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
@ -782,12 +782,12 @@ private:
|
|||
ScopedPointer <Component> popupDisplay;
|
||||
Component* parentForPopupDisplay;
|
||||
|
||||
float getLinearSliderPos (const double value);
|
||||
float getLinearSliderPos (double value);
|
||||
void restoreMouseIfHidden();
|
||||
void sendDragStart();
|
||||
void sendDragEnd();
|
||||
double constrainedValue (double value) const;
|
||||
void triggerChangeMessage (const bool synchronous);
|
||||
void triggerChangeMessage (bool synchronous);
|
||||
bool incDecDragDirectionIsHorizontal() const;
|
||||
|
||||
Slider (const Slider&);
|
||||
|
|
|
|||
|
|
@ -148,19 +148,19 @@ public:
|
|||
all columns, not just the index amongst those that are currently visible
|
||||
*/
|
||||
void addColumn (const String& columnName,
|
||||
const int columnId,
|
||||
const int width,
|
||||
const int minimumWidth = 30,
|
||||
const int maximumWidth = -1,
|
||||
const int propertyFlags = defaultFlags,
|
||||
const int insertIndex = -1);
|
||||
int columnId,
|
||||
int width,
|
||||
int minimumWidth = 30,
|
||||
int maximumWidth = -1,
|
||||
int propertyFlags = defaultFlags,
|
||||
int insertIndex = -1);
|
||||
|
||||
/** Removes a column with the given ID.
|
||||
|
||||
If there is such a column, this will asynchronously call the tableColumnsChanged() method of any
|
||||
registered listeners.
|
||||
*/
|
||||
void removeColumn (const int columnIdToRemove);
|
||||
void removeColumn (int columnIdToRemove);
|
||||
|
||||
/** Deletes all columns from the table.
|
||||
|
||||
|
|
@ -176,44 +176,44 @@ public:
|
|||
|
||||
@see isColumnVisible
|
||||
*/
|
||||
int getNumColumns (const bool onlyCountVisibleColumns) const;
|
||||
int getNumColumns (bool onlyCountVisibleColumns) const;
|
||||
|
||||
/** Returns the name for a column.
|
||||
@see setColumnName
|
||||
*/
|
||||
const String getColumnName (const int columnId) const;
|
||||
const String getColumnName (int columnId) const;
|
||||
|
||||
/** Changes the name of a column. */
|
||||
void setColumnName (const int columnId, const String& newName);
|
||||
void setColumnName (int columnId, const String& newName);
|
||||
|
||||
/** Moves a column to a different index in the table.
|
||||
|
||||
@param columnId the column to move
|
||||
@param newVisibleIndex the target index for it, from 0 to the number of columns currently visible.
|
||||
*/
|
||||
void moveColumn (const int columnId, int newVisibleIndex);
|
||||
void moveColumn (int columnId, int newVisibleIndex);
|
||||
|
||||
/** Returns the width of one of the columns.
|
||||
*/
|
||||
int getColumnWidth (const int columnId) const;
|
||||
int getColumnWidth (int columnId) const;
|
||||
|
||||
/** Changes the width of a column.
|
||||
|
||||
This will cause an asynchronous callback to the tableColumnsResized() method of any registered listeners.
|
||||
*/
|
||||
void setColumnWidth (const int columnId, const int newWidth);
|
||||
void setColumnWidth (int columnId, int newWidth);
|
||||
|
||||
/** Shows or hides a column.
|
||||
|
||||
This can cause an asynchronous callback to the tableColumnsChanged() method of any registered listeners.
|
||||
@see isColumnVisible
|
||||
*/
|
||||
void setColumnVisible (const int columnId, const bool shouldBeVisible);
|
||||
void setColumnVisible (int columnId, bool shouldBeVisible);
|
||||
|
||||
/** Returns true if this column is currently visible.
|
||||
@see setColumnVisible
|
||||
*/
|
||||
bool isColumnVisible (const int columnId) const;
|
||||
bool isColumnVisible (int columnId) const;
|
||||
|
||||
/** Changes the column which is the sort column.
|
||||
|
||||
|
|
@ -224,7 +224,7 @@ public:
|
|||
|
||||
@see getSortColumnId, isSortedForwards, reSortTable
|
||||
*/
|
||||
void setSortColumnId (const int columnId, const bool sortForwards);
|
||||
void setSortColumnId (int columnId, bool sortForwards);
|
||||
|
||||
/** Returns the column ID by which the table is currently sorted, or 0 if it is unsorted.
|
||||
|
||||
|
|
@ -259,7 +259,7 @@ public:
|
|||
If onlyCountVisibleColumns is true, this will return the index amoungst the visible columns;
|
||||
otherwise it'll return the index amongst all the columns, including any hidden ones.
|
||||
*/
|
||||
int getIndexOfColumnId (const int columnId, const bool onlyCountVisibleColumns) const;
|
||||
int getIndexOfColumnId (int columnId, bool onlyCountVisibleColumns) const;
|
||||
|
||||
/** Returns the ID of the column at a given index.
|
||||
|
||||
|
|
@ -268,7 +268,7 @@ public:
|
|||
|
||||
If the index is out-of-range, it'll return 0.
|
||||
*/
|
||||
int getColumnIdOfIndex (int index, const bool onlyCountVisibleColumns) const;
|
||||
int getColumnIdOfIndex (int index, bool onlyCountVisibleColumns) const;
|
||||
|
||||
/** Returns the rectangle containing of one of the columns.
|
||||
|
||||
|
|
@ -276,13 +276,13 @@ public:
|
|||
ones are not counted). It returns a rectangle showing the position of the column relative
|
||||
to this component's top-left. If the index is out-of-range, an empty rectangle is retrurned.
|
||||
*/
|
||||
const Rectangle<int> getColumnPosition (const int index) const;
|
||||
const Rectangle<int> getColumnPosition (int index) const;
|
||||
|
||||
/** Finds the column ID at a given x-position in the component.
|
||||
|
||||
If there is a column at this point this returns its ID, or if not, it will return 0.
|
||||
*/
|
||||
int getColumnIdAtX (const int xToFind) const;
|
||||
int getColumnIdAtX (int xToFind) const;
|
||||
|
||||
/** If set to true, this indicates that the columns should be expanded or shrunk to fill the
|
||||
entire width of the component.
|
||||
|
|
@ -290,7 +290,7 @@ public:
|
|||
By default this is disabled. Turning it on also means that when resizing a column, those
|
||||
on the right will be squashed to fit.
|
||||
*/
|
||||
void setStretchToFitActive (const bool shouldStretchToFit);
|
||||
void setStretchToFitActive (bool shouldStretchToFit);
|
||||
|
||||
/** Returns true if stretch-to-fit has been enabled.
|
||||
@see setStretchToFitActive
|
||||
|
|
@ -315,7 +315,7 @@ public:
|
|||
|
||||
@see isPopupMenuActive, addMenuItems, reactToMenuItem
|
||||
*/
|
||||
void setPopupMenuActive (const bool hasMenu);
|
||||
void setPopupMenuActive (bool hasMenu);
|
||||
|
||||
/** Returns true if the pop-up menu is enabled.
|
||||
@see setPopupMenuActive
|
||||
|
|
@ -341,10 +341,10 @@ public:
|
|||
|
||||
//==============================================================================
|
||||
/** Adds a listener to be informed about things that happen to the header. */
|
||||
void addListener (TableHeaderListener* const newListener);
|
||||
void addListener (TableHeaderListener* newListener);
|
||||
|
||||
/** Removes a previously-registered listener. */
|
||||
void removeListener (TableHeaderListener* const listenerToRemove);
|
||||
void removeListener (TableHeaderListener* listenerToRemove);
|
||||
|
||||
//==============================================================================
|
||||
/** This can be overridden to handle a mouse-click on one of the column headers.
|
||||
|
|
@ -363,7 +363,7 @@ public:
|
|||
|
||||
@see reactToMenuItem
|
||||
*/
|
||||
virtual void addMenuItems (PopupMenu& menu, const int columnIdClicked);
|
||||
virtual void addMenuItems (PopupMenu& menu, int columnIdClicked);
|
||||
|
||||
/** Override this to handle any custom items that you have added to the
|
||||
pop-up menu with an addMenuItems() override.
|
||||
|
|
@ -374,7 +374,7 @@ public:
|
|||
|
||||
@see addMenuItems
|
||||
*/
|
||||
virtual void reactToMenuItem (const int menuReturnId, const int columnIdClicked);
|
||||
virtual void reactToMenuItem (int menuReturnId, int columnIdClicked);
|
||||
|
||||
//==============================================================================
|
||||
/** @internal */
|
||||
|
|
@ -397,7 +397,7 @@ public:
|
|||
const MouseCursor getMouseCursor();
|
||||
|
||||
/** Can be overridden for more control over the pop-up menu behaviour. */
|
||||
virtual void showColumnChooserMenu (const int columnIdClicked);
|
||||
virtual void showColumnChooserMenu (int columnIdClicked);
|
||||
|
||||
juce_UseDebuggingNewOperator
|
||||
|
||||
|
|
@ -419,13 +419,13 @@ private:
|
|||
int columnIdBeingResized, columnIdBeingDragged, initialColumnWidth;
|
||||
int columnIdUnderMouse, draggingColumnOffset, draggingColumnOriginalIndex, lastDeliberateWidth;
|
||||
|
||||
ColumnInfo* getInfoForId (const int columnId) const;
|
||||
int visibleIndexToTotalIndex (const int visibleIndex) const;
|
||||
ColumnInfo* getInfoForId (int columnId) const;
|
||||
int visibleIndexToTotalIndex (int visibleIndex) const;
|
||||
void sendColumnsChanged();
|
||||
void handleAsyncUpdate();
|
||||
void beginDrag (const MouseEvent&);
|
||||
void endDrag (const int finalIndex);
|
||||
int getResizeDraggerAt (const int mouseX) const;
|
||||
void endDrag (int finalIndex);
|
||||
int getResizeDraggerAt (int mouseX) const;
|
||||
void updateColumnUnderMouse (int x, int y);
|
||||
void resizeColumnsToFit (int firstColumnIndex, int targetTotalWidth);
|
||||
|
||||
|
|
|
|||
|
|
@ -130,7 +130,7 @@ public:
|
|||
If you implement this, your method should re-sort the table using the given
|
||||
column as the key.
|
||||
*/
|
||||
virtual void sortOrderChanged (int newSortColumnId, const bool isForwards);
|
||||
virtual void sortOrderChanged (int newSortColumnId, bool isForwards);
|
||||
|
||||
//==============================================================================
|
||||
/** Returns the best width for one of the columns.
|
||||
|
|
@ -209,7 +209,7 @@ public:
|
|||
with setModel().
|
||||
*/
|
||||
TableListBox (const String& componentName,
|
||||
TableListBoxModel* const model);
|
||||
TableListBoxModel* model);
|
||||
|
||||
/** Destructor. */
|
||||
~TableListBox();
|
||||
|
|
@ -217,7 +217,7 @@ public:
|
|||
//==============================================================================
|
||||
/** Changes the TableListBoxModel that is being used for this table.
|
||||
*/
|
||||
void setModel (TableListBoxModel* const newModel);
|
||||
void setModel (TableListBoxModel* newModel);
|
||||
|
||||
/** Returns the model currently in use. */
|
||||
TableListBoxModel* getModel() const { return model; }
|
||||
|
|
@ -229,7 +229,7 @@ public:
|
|||
/** Changes the height of the table header component.
|
||||
@see getHeaderHeight
|
||||
*/
|
||||
void setHeaderHeight (const int newHeight);
|
||||
void setHeaderHeight (int newHeight);
|
||||
|
||||
/** Returns the height of the table header.
|
||||
@see setHeaderHeight
|
||||
|
|
@ -244,7 +244,7 @@ public:
|
|||
|
||||
@see autoSizeAllColumns, TableHeaderComponent::setColumnWidth
|
||||
*/
|
||||
void autoSizeColumn (const int columnId);
|
||||
void autoSizeColumn (int columnId);
|
||||
|
||||
/** Calls autoSizeColumn() for all columns in the table. */
|
||||
void autoSizeAllColumns();
|
||||
|
|
@ -253,7 +253,7 @@ public:
|
|||
|
||||
By default, these are enabled.
|
||||
*/
|
||||
void setAutoSizeMenuOptionShown (const bool shouldBeShown);
|
||||
void setAutoSizeMenuOptionShown (bool shouldBeShown);
|
||||
|
||||
/** True if the auto-size options should be shown on the menu.
|
||||
@see setAutoSizeMenuOptionsShown
|
||||
|
|
@ -269,15 +269,15 @@ public:
|
|||
If relativeToComponentTopLeft is false, the co-ords are relative to the
|
||||
top-left of the table's top-left cell.
|
||||
*/
|
||||
const Rectangle<int> getCellPosition (const int columnId,
|
||||
const int rowNumber,
|
||||
const bool relativeToComponentTopLeft) const;
|
||||
const Rectangle<int> getCellPosition (int columnId,
|
||||
int rowNumber,
|
||||
bool relativeToComponentTopLeft) const;
|
||||
|
||||
/** Scrolls horizontally if necessary to make sure that a particular column is visible.
|
||||
|
||||
@see ListBox::scrollToEnsureRowIsOnscreen
|
||||
*/
|
||||
void scrollToEnsureColumnIsOnscreen (const int columnId);
|
||||
void scrollToEnsureColumnIsOnscreen (int columnId);
|
||||
|
||||
//==============================================================================
|
||||
/** @internal */
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ public:
|
|||
which is a bullet (probably the best choice for linux).
|
||||
*/
|
||||
TextEditor (const String& componentName = String::empty,
|
||||
const tchar passwordCharacter = 0);
|
||||
tchar passwordCharacter = 0);
|
||||
|
||||
/** Destructor. */
|
||||
virtual ~TextEditor();
|
||||
|
|
@ -107,8 +107,8 @@ public:
|
|||
|
||||
@see isMultiLine, setReturnKeyStartsNewLine
|
||||
*/
|
||||
void setMultiLine (const bool shouldBeMultiLine,
|
||||
const bool shouldWordWrap = true);
|
||||
void setMultiLine (bool shouldBeMultiLine,
|
||||
bool shouldWordWrap = true);
|
||||
|
||||
/** Returns true if the editor is in multi-line mode.
|
||||
*/
|
||||
|
|
@ -122,7 +122,7 @@ public:
|
|||
method. By default this is set to false, and when true it will only insert
|
||||
new-lines when in multi-line mode (see setMultiLine()).
|
||||
*/
|
||||
void setReturnKeyStartsNewLine (const bool shouldStartNewLine);
|
||||
void setReturnKeyStartsNewLine (bool shouldStartNewLine);
|
||||
|
||||
/** Returns the value set by setReturnKeyStartsNewLine().
|
||||
|
||||
|
|
@ -136,7 +136,7 @@ public:
|
|||
By default the tab key is ignored, so that it can be used to switch keyboard focus
|
||||
between components.
|
||||
*/
|
||||
void setTabKeyUsedAsCharacter (const bool shouldTabKeyBeUsed);
|
||||
void setTabKeyUsedAsCharacter (bool shouldTabKeyBeUsed);
|
||||
|
||||
/** Returns true if the tab key is being used for input.
|
||||
@see setTabKeyUsedAsCharacter
|
||||
|
|
@ -153,7 +153,7 @@ public:
|
|||
|
||||
@see isReadOnly, setCaretVisible
|
||||
*/
|
||||
void setReadOnly (const bool shouldBeReadOnly);
|
||||
void setReadOnly (bool shouldBeReadOnly);
|
||||
|
||||
/** Returns true if the editor is in read-only mode.
|
||||
*/
|
||||
|
|
@ -166,7 +166,7 @@ public:
|
|||
|
||||
@see setCaretColour, setCaretPosition
|
||||
*/
|
||||
void setCaretVisible (const bool shouldBeVisible);
|
||||
void setCaretVisible (bool shouldBeVisible);
|
||||
|
||||
/** Returns true if the caret is enabled.
|
||||
@see setCaretVisible
|
||||
|
|
@ -199,7 +199,7 @@ public:
|
|||
for a black splodge (not all fonts include this, though), or 0x2022,
|
||||
which is a bullet (probably the best choice for linux).
|
||||
*/
|
||||
void setPasswordCharacter (const tchar passwordCharacter);
|
||||
void setPasswordCharacter (tchar passwordCharacter);
|
||||
|
||||
/** Returns the current password character.
|
||||
@see setPasswordCharacter
|
||||
|
|
@ -215,7 +215,7 @@ l */
|
|||
If enabled, right-clicking (or command-clicking on the Mac) will pop up a menu
|
||||
of options such as cut/copy/paste, undo/redo, etc.
|
||||
*/
|
||||
void setPopupMenuEnabled (const bool menuEnabled);
|
||||
void setPopupMenuEnabled (bool menuEnabled);
|
||||
|
||||
/** Returns true if the right-click menu is enabled.
|
||||
@see setPopupMenuEnabled
|
||||
|
|
@ -295,7 +295,7 @@ l */
|
|||
This is useful for boxes where you expect the user to re-enter all the
|
||||
text when they focus on the component, rather than editing what's already there.
|
||||
*/
|
||||
void setSelectAllWhenFocused (const bool b);
|
||||
void setSelectAllWhenFocused (bool b);
|
||||
|
||||
/** Sets limits on the characters that can be entered.
|
||||
|
||||
|
|
@ -304,7 +304,7 @@ l */
|
|||
@param allowedCharacters if this is non-empty, then only characters that occur in
|
||||
this string are allowed to be entered into the editor.
|
||||
*/
|
||||
void setInputRestrictions (const int maxTextLength,
|
||||
void setInputRestrictions (int maxTextLength,
|
||||
const String& allowedCharacters = String::empty);
|
||||
|
||||
/** When the text editor is empty, it can be set to display a message.
|
||||
|
|
@ -320,26 +320,26 @@ l */
|
|||
|
||||
Handy if you need smaller scrollbars for a small text box.
|
||||
*/
|
||||
void setScrollBarThickness (const int newThicknessPixels);
|
||||
void setScrollBarThickness (int newThicknessPixels);
|
||||
|
||||
/** Shows or hides the buttons on any scrollbars that are used.
|
||||
|
||||
@see ScrollBar::setButtonVisibility
|
||||
*/
|
||||
void setScrollBarButtonVisibility (const bool buttonsVisible);
|
||||
void setScrollBarButtonVisibility (bool buttonsVisible);
|
||||
|
||||
//==============================================================================
|
||||
/** Registers a listener to be told when things happen to the text.
|
||||
|
||||
@see removeListener
|
||||
*/
|
||||
void addListener (TextEditorListener* const newListener);
|
||||
void addListener (TextEditorListener* newListener);
|
||||
|
||||
/** Deregisters a listener.
|
||||
|
||||
@see addListener
|
||||
*/
|
||||
void removeListener (TextEditorListener* const listenerToRemove);
|
||||
void removeListener (TextEditorListener* listenerToRemove);
|
||||
|
||||
//==============================================================================
|
||||
/** Returns the entire contents of the editor. */
|
||||
|
|
@ -367,7 +367,7 @@ l */
|
|||
@see insertText
|
||||
*/
|
||||
void setText (const String& newText,
|
||||
const bool sendTextChangeMessage = true);
|
||||
bool sendTextChangeMessage = true);
|
||||
|
||||
/** Returns a Value object that can be used to get or set the text.
|
||||
|
||||
|
|
@ -415,7 +415,7 @@ l */
|
|||
|
||||
@see getCaretPosition
|
||||
*/
|
||||
void setCaretPosition (const int newIndex);
|
||||
void setCaretPosition (int newIndex);
|
||||
|
||||
/** Returns the current index of the caret.
|
||||
|
||||
|
|
@ -434,8 +434,7 @@ l */
|
|||
scroll far enough for the caret to reach this exact position, but it
|
||||
will go as far as it can in that direction.
|
||||
*/
|
||||
void scrollEditorToPositionCaret (const int desiredCaretX,
|
||||
const int desiredCaretY);
|
||||
void scrollEditorToPositionCaret (int desiredCaretX, int desiredCaretY);
|
||||
|
||||
/** Get the graphical position of the caret.
|
||||
|
||||
|
|
@ -460,7 +459,7 @@ l */
|
|||
|
||||
The co-ordinates are relative to the component's top-left.
|
||||
*/
|
||||
int getTextIndexAt (const int x, const int y);
|
||||
int getTextIndexAt (int x, int y);
|
||||
|
||||
/** Counts the number of characters in the text.
|
||||
|
||||
|
|
@ -487,7 +486,7 @@ l */
|
|||
|
||||
By default there's a gap of 4 pixels.
|
||||
*/
|
||||
void setIndents (const int newLeftIndent, const int newTopIndent);
|
||||
void setIndents (int newLeftIndent, int newTopIndent);
|
||||
|
||||
/** Changes the size of border left around the edge of the component.
|
||||
|
||||
|
|
@ -506,7 +505,7 @@ l */
|
|||
If true (the default), the editor will scroll when the cursor moves offscreen. If
|
||||
set to false, it won't.
|
||||
*/
|
||||
void setScrollToShowCursor (const bool shouldScrollToShowCursor);
|
||||
void setScrollToShowCursor (bool shouldScrollToShowCursor);
|
||||
|
||||
//==============================================================================
|
||||
/** @internal */
|
||||
|
|
@ -526,7 +525,7 @@ l */
|
|||
/** @internal */
|
||||
bool keyPressed (const KeyPress& key);
|
||||
/** @internal */
|
||||
bool keyStateChanged (const bool isKeyDown);
|
||||
bool keyStateChanged (bool isKeyDown);
|
||||
/** @internal */
|
||||
void focusGained (FocusChangeType cause);
|
||||
/** @internal */
|
||||
|
|
@ -577,7 +576,7 @@ protected:
|
|||
|
||||
@see addPopupMenuItems, setPopupMenuEnabled, isPopupMenuEnabled
|
||||
*/
|
||||
virtual void performPopupMenuAction (const int menuItemID);
|
||||
virtual void performPopupMenuAction (int menuItemID);
|
||||
|
||||
//==============================================================================
|
||||
/** Scrolls the minimum distance needed to get the caret into view. */
|
||||
|
|
@ -587,7 +586,7 @@ protected:
|
|||
void moveCaret (int newCaretPos);
|
||||
|
||||
/** @internal */
|
||||
void moveCursorTo (const int newPosition, const bool isSelecting);
|
||||
void moveCursorTo (int newPosition, bool isSelecting);
|
||||
|
||||
/** Used internally to dispatch a text-change message. */
|
||||
void textChanged();
|
||||
|
|
@ -597,7 +596,7 @@ protected:
|
|||
void newTransaction();
|
||||
|
||||
/** Used internally to trigger an undo or redo. */
|
||||
void doUndoRedo (const bool isRedo);
|
||||
void doUndoRedo (bool isRedo);
|
||||
|
||||
/** Can be overridden to intercept return key presses directly */
|
||||
virtual void returnPressed();
|
||||
|
|
@ -658,37 +657,18 @@ private:
|
|||
friend class TextEditorRemoveAction;
|
||||
|
||||
void coalesceSimilarSections();
|
||||
void splitSection (const int sectionIndex, const int charToSplitAt);
|
||||
|
||||
void clearInternal (UndoManager* const um);
|
||||
|
||||
void insert (const String& text,
|
||||
const int insertIndex,
|
||||
const Font& font,
|
||||
const Colour& colour,
|
||||
UndoManager* const um,
|
||||
const int caretPositionToMoveTo);
|
||||
|
||||
void reinsert (const int insertIndex,
|
||||
const VoidArray& sections);
|
||||
|
||||
void remove (const Range<int>& range,
|
||||
UndoManager* const um,
|
||||
const int caretPositionToMoveTo);
|
||||
|
||||
void getCharPosition (const int index,
|
||||
float& x, float& y,
|
||||
float& lineHeight) const;
|
||||
|
||||
void splitSection (int sectionIndex, int charToSplitAt);
|
||||
void clearInternal (UndoManager* um);
|
||||
void insert (const String& text, int insertIndex, const Font& font,
|
||||
const Colour& colour, UndoManager* um, int caretPositionToMoveTo);
|
||||
void reinsert (int insertIndex, const VoidArray& sections);
|
||||
void remove (const Range<int>& range, UndoManager* um, int caretPositionToMoveTo);
|
||||
void getCharPosition (int index, float& x, float& y, float& lineHeight) const;
|
||||
void updateCaretPosition();
|
||||
|
||||
void textWasChangedByValue();
|
||||
|
||||
int indexAtPosition (const float x,
|
||||
const float y);
|
||||
|
||||
int findWordBreakAfter (const int position) const;
|
||||
int findWordBreakBefore (const int position) const;
|
||||
int indexAtPosition (float x, float y);
|
||||
int findWordBreakAfter (int position) const;
|
||||
int findWordBreakBefore (int position) const;
|
||||
|
||||
friend class TextHolderComponent;
|
||||
friend class TextEditorViewport;
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ public:
|
|||
/** Changes the bar's orientation.
|
||||
@see isVertical
|
||||
*/
|
||||
void setVertical (const bool shouldBeVertical);
|
||||
void setVertical (bool shouldBeVertical);
|
||||
|
||||
/** Returns true if the bar is set to be vertical, or false if it's horizontal.
|
||||
|
||||
|
|
@ -123,12 +123,12 @@ public:
|
|||
@see ToolbarItemFactory
|
||||
*/
|
||||
void addItem (ToolbarItemFactory& factory,
|
||||
const int itemId,
|
||||
const int insertIndex = -1);
|
||||
int itemId,
|
||||
int insertIndex = -1);
|
||||
|
||||
/** Deletes one of the items from the bar.
|
||||
*/
|
||||
void removeToolbarItem (const int itemIndex);
|
||||
void removeToolbarItem (int itemIndex);
|
||||
|
||||
/** Returns the number of items currently on the toolbar.
|
||||
|
||||
|
|
@ -143,7 +143,7 @@ public:
|
|||
|
||||
@see getNumItems
|
||||
*/
|
||||
int getItemId (const int itemIndex) const throw();
|
||||
int getItemId (int itemIndex) const throw();
|
||||
|
||||
/** Returns the component being used for the item with the given index.
|
||||
|
||||
|
|
@ -152,7 +152,7 @@ public:
|
|||
|
||||
@see getNumItems
|
||||
*/
|
||||
ToolbarItemComponent* getItemComponent (const int itemIndex) const throw();
|
||||
ToolbarItemComponent* getItemComponent (int itemIndex) const throw();
|
||||
|
||||
/** Clears this toolbar and adds to it the default set of items that the specified
|
||||
factory creates.
|
||||
|
|
@ -213,7 +213,7 @@ public:
|
|||
@see ToolbarItemPalette
|
||||
*/
|
||||
void showCustomisationDialog (ToolbarItemFactory& factory,
|
||||
const int optionFlags = allCustomisationOptionsEnabled);
|
||||
int optionFlags = allCustomisationOptionsEnabled);
|
||||
|
||||
/** Turns on or off the toolbar's editing mode, in which its items can be
|
||||
rearranged by the user.
|
||||
|
|
@ -223,7 +223,7 @@ public:
|
|||
|
||||
@see ToolbarItemPalette
|
||||
*/
|
||||
void setEditingActive (const bool editingEnabled);
|
||||
void setEditingActive (bool editingEnabled);
|
||||
|
||||
//==============================================================================
|
||||
/** A set of colour IDs to use to change the colour of various aspects of the toolbar.
|
||||
|
|
|
|||
|
|
@ -63,9 +63,9 @@ public:
|
|||
to draw itself with button over/down states when the mouse
|
||||
moves over it or clicks
|
||||
*/
|
||||
ToolbarItemComponent (const int itemId,
|
||||
ToolbarItemComponent (int itemId,
|
||||
const String& labelText,
|
||||
const bool isBeingUsedAsAButton);
|
||||
bool isBeingUsedAsAButton);
|
||||
|
||||
/** Destructor. */
|
||||
~ToolbarItemComponent();
|
||||
|
|
|
|||
|
|
@ -104,7 +104,7 @@ public:
|
|||
automatically by the toolbar, and remember that multiple instances of the same
|
||||
item type are likely to exist at the same time.
|
||||
*/
|
||||
virtual ToolbarItemComponent* createItem (const int itemId) = 0;
|
||||
virtual ToolbarItemComponent* createItem (int itemId) = 0;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ public:
|
|||
The toolbar and factory must not be deleted while this object exists.
|
||||
*/
|
||||
ToolbarItemPalette (ToolbarItemFactory& factory,
|
||||
Toolbar* const toolbar);
|
||||
Toolbar* toolbar);
|
||||
|
||||
/** Destructor. */
|
||||
~ToolbarItemPalette();
|
||||
|
|
@ -71,7 +71,7 @@ private:
|
|||
Viewport* viewport;
|
||||
|
||||
friend class Toolbar;
|
||||
void replaceComponent (ToolbarItemComponent* const comp);
|
||||
void replaceComponent (ToolbarItemComponent* comp);
|
||||
|
||||
ToolbarItemPalette (const ToolbarItemPalette&);
|
||||
ToolbarItemPalette& operator= (const ToolbarItemPalette&);
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ public:
|
|||
|
||||
@see getNumSubItems
|
||||
*/
|
||||
TreeViewItem* getSubItem (const int index) const throw();
|
||||
TreeViewItem* getSubItem (int index) const throw();
|
||||
|
||||
/** Removes any sub-items. */
|
||||
void clearSubItems();
|
||||
|
|
@ -87,16 +87,14 @@ public:
|
|||
@param insertPosition the index which the new item should have when it's added. If this
|
||||
value is less than 0, the item will be added to the end of the list.
|
||||
*/
|
||||
void addSubItem (TreeViewItem* const newItem,
|
||||
const int insertPosition = -1);
|
||||
void addSubItem (TreeViewItem* newItem, int insertPosition = -1);
|
||||
|
||||
/** Removes one of the sub-items.
|
||||
|
||||
@param index the item to remove
|
||||
@param deleteItem if true, the item that is removed will also be deleted.
|
||||
*/
|
||||
void removeSubItem (const int index,
|
||||
const bool deleteItem = true);
|
||||
void removeSubItem (int index, bool deleteItem = true);
|
||||
|
||||
//==============================================================================
|
||||
/** Returns the TreeView to which this item belongs. */
|
||||
|
|
@ -117,7 +115,7 @@ public:
|
|||
|
||||
@see itemOpennessChanged, mightContainSubItems
|
||||
*/
|
||||
void setOpen (const bool shouldBeOpen);
|
||||
void setOpen (bool shouldBeOpen);
|
||||
|
||||
/** True if this item is currently selected.
|
||||
|
||||
|
|
@ -129,8 +127,8 @@ public:
|
|||
|
||||
This will cause a callback to itemSelectionChanged()
|
||||
*/
|
||||
void setSelected (const bool shouldBeSelected,
|
||||
const bool deselectOtherItemsFirst);
|
||||
void setSelected (bool shouldBeSelected,
|
||||
bool deselectOtherItemsFirst);
|
||||
|
||||
/** Returns the rectangle that this item occupies.
|
||||
|
||||
|
|
@ -139,7 +137,7 @@ public:
|
|||
the tree. If false, it is relative to the top-left of the topmost item in the
|
||||
tree (so this would be unaffected by scrolling the view).
|
||||
*/
|
||||
const Rectangle<int> getItemPosition (const bool relativeToTreeViewTopLeft) const throw();
|
||||
const Rectangle<int> getItemPosition (bool relativeToTreeViewTopLeft) const throw();
|
||||
|
||||
/** Sends a signal to the treeview to make it refresh itself.
|
||||
|
||||
|
|
@ -173,7 +171,7 @@ public:
|
|||
|
||||
By default, line-drawing is turned on.
|
||||
*/
|
||||
void setLinesDrawnForSubItems (const bool shouldDrawLines) throw();
|
||||
void setLinesDrawnForSubItems (bool shouldDrawLines) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Tells the tree whether this item can potentially be opened.
|
||||
|
|
@ -479,7 +477,7 @@ private:
|
|||
|
||||
void updatePositions (int newY);
|
||||
int getIndentX() const throw();
|
||||
void setOwnerView (TreeView* const newOwner) throw();
|
||||
void setOwnerView (TreeView* newOwner) throw();
|
||||
void paintRecursively (Graphics& g, int width);
|
||||
TreeViewItem* getTopLevelItem() throw();
|
||||
TreeViewItem* findItemRecursively (int y) throw();
|
||||
|
|
@ -489,7 +487,7 @@ private:
|
|||
void deselectAllRecursively();
|
||||
int countSelectedItemsRecursively() const throw();
|
||||
TreeViewItem* getSelectedItemWithIndex (int index) throw();
|
||||
TreeViewItem* getNextVisibleItem (const bool recurse) const throw();
|
||||
TreeViewItem* getNextVisibleItem (bool recurse) const throw();
|
||||
TreeViewItem* findItemFromIdentifierString (const String& identifierString);
|
||||
|
||||
TreeViewItem (const TreeViewItem&);
|
||||
|
|
@ -537,7 +535,7 @@ public:
|
|||
or by deleting the tree first. You can also use deleteRootItem() as a quick way
|
||||
to delete it.
|
||||
*/
|
||||
void setRootItem (TreeViewItem* const newRootItem);
|
||||
void setRootItem (TreeViewItem* newRootItem);
|
||||
|
||||
/** Returns the tree's root item.
|
||||
|
||||
|
|
@ -557,7 +555,7 @@ public:
|
|||
lets you make the tree look as if it's got many root items. If it's hidden, this call
|
||||
will also make sure the root item is open (otherwise the treeview would look empty).
|
||||
*/
|
||||
void setRootItemVisible (const bool shouldBeVisible);
|
||||
void setRootItemVisible (bool shouldBeVisible);
|
||||
|
||||
/** Returns true if the root item is visible.
|
||||
|
||||
|
|
@ -572,7 +570,7 @@ public:
|
|||
|
||||
@see areItemsOpenByDefault
|
||||
*/
|
||||
void setDefaultOpenness (const bool isOpenByDefault);
|
||||
void setDefaultOpenness (bool isOpenByDefault);
|
||||
|
||||
/** Returns true if the tree's items default to being open.
|
||||
|
||||
|
|
@ -590,7 +588,7 @@ public:
|
|||
|
||||
@see isMultiSelectEnabled
|
||||
*/
|
||||
void setMultiSelectEnabled (const bool canMultiSelect);
|
||||
void setMultiSelectEnabled (bool canMultiSelect);
|
||||
|
||||
/** Returns whether multi-select has been enabled for the tree.
|
||||
|
||||
|
|
@ -602,7 +600,7 @@ public:
|
|||
|
||||
@see areOpenCloseButtonsVisible
|
||||
*/
|
||||
void setOpenCloseButtonsVisible (const bool shouldBeVisible);
|
||||
void setOpenCloseButtonsVisible (bool shouldBeVisible);
|
||||
|
||||
/** Returns whether open/close buttons are shown.
|
||||
|
||||
|
|
@ -624,7 +622,7 @@ public:
|
|||
|
||||
@param index the index, 0 to (getNumSelectedItems() - 1)
|
||||
*/
|
||||
TreeViewItem* getSelectedItem (const int index) const throw();
|
||||
TreeViewItem* getSelectedItem (int index) const throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Returns the number of rows the tree is using.
|
||||
|
|
@ -662,7 +660,7 @@ public:
|
|||
/** Changes the distance by which each nested level of the tree is indented.
|
||||
@see getIndentSize
|
||||
*/
|
||||
void setIndentSize (const int newIndentSize);
|
||||
void setIndentSize (int newIndentSize);
|
||||
|
||||
/** Searches the tree for an item with the specified identifier.
|
||||
The identifer string must have been created by calling TreeViewItem::getItemIdentifierString().
|
||||
|
|
@ -689,7 +687,7 @@ public:
|
|||
so this can also be restored
|
||||
@see restoreOpennessState
|
||||
*/
|
||||
XmlElement* getOpennessState (const bool alsoIncludeScrollPosition) const;
|
||||
XmlElement* getOpennessState (bool alsoIncludeScrollPosition) const;
|
||||
|
||||
/** Restores a previously saved arrangement of open/closed nodes.
|
||||
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ public:
|
|||
@param isKeyDown true if a key is being pressed, false if one is being released
|
||||
@see KeyPress, Component::keyStateChanged
|
||||
*/
|
||||
virtual bool keyStateChanged (const bool isKeyDown, Component* originatingComponent);
|
||||
virtual bool keyStateChanged (bool isKeyDown, Component* originatingComponent);
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -54,8 +54,8 @@ public:
|
|||
list, the component will include a 'reset to
|
||||
defaults' button.
|
||||
*/
|
||||
KeyMappingEditorComponent (KeyPressMappingSet* const mappingSet,
|
||||
const bool showResetToDefaultButton);
|
||||
KeyMappingEditorComponent (KeyPressMappingSet* mappingSet,
|
||||
bool showResetToDefaultButton);
|
||||
|
||||
/** Destructor. */
|
||||
virtual ~KeyMappingEditorComponent();
|
||||
|
|
@ -80,14 +80,14 @@ public:
|
|||
By default this will use the KeyPressMappingSet's shouldCommandBeVisibleInEditor()
|
||||
method to decide what to return, but you can override it to handle special cases.
|
||||
*/
|
||||
virtual bool shouldCommandBeIncluded (const CommandID commandID);
|
||||
virtual bool shouldCommandBeIncluded (CommandID commandID);
|
||||
|
||||
/** Can be overridden to indicate that some commands are shown as read-only.
|
||||
|
||||
By default this will use the KeyPressMappingSet's shouldCommandBeReadOnlyInEditor()
|
||||
method to decide what to return, but you can override it to handle special cases.
|
||||
*/
|
||||
virtual bool isCommandReadOnly (const CommandID commandID);
|
||||
virtual bool isCommandReadOnly (CommandID commandID);
|
||||
|
||||
/** This can be overridden to let you change the format of the string used
|
||||
to describe a keypress.
|
||||
|
|
@ -141,7 +141,7 @@ private:
|
|||
friend class KeyMappingChangeButton;
|
||||
TextButton* resetButton;
|
||||
|
||||
void assignNewKey (const CommandID commandID, int index);
|
||||
void assignNewKey (CommandID commandID, int index);
|
||||
|
||||
KeyMappingEditorComponent (const KeyMappingEditorComponent&);
|
||||
KeyMappingEditorComponent& operator= (const KeyMappingEditorComponent&);
|
||||
|
|
|
|||
|
|
@ -67,13 +67,13 @@ public:
|
|||
null if the keypress is a non-printing character
|
||||
@see getKeyCode, isKeyCode, getModifiers
|
||||
*/
|
||||
KeyPress (const int keyCode,
|
||||
KeyPress (int keyCode,
|
||||
const ModifierKeys& modifiers,
|
||||
const juce_wchar textCharacter) throw();
|
||||
juce_wchar textCharacter) throw();
|
||||
|
||||
/** Creates a keypress with a keyCode but no modifiers or text character.
|
||||
*/
|
||||
KeyPress (const int keyCode) throw();
|
||||
KeyPress (int keyCode) throw();
|
||||
|
||||
/** Creates a copy of another KeyPress. */
|
||||
KeyPress (const KeyPress& other) throw();
|
||||
|
|
@ -123,7 +123,7 @@ public:
|
|||
|
||||
@see getKeyCode
|
||||
*/
|
||||
bool isKeyCode (const int keyCodeToCompare) const throw() { return keyCode == keyCodeToCompare; }
|
||||
bool isKeyCode (int keyCodeToCompare) const throw() { return keyCode == keyCodeToCompare; }
|
||||
|
||||
//==============================================================================
|
||||
/** Converts a textual key description to a KeyPress.
|
||||
|
|
|
|||
|
|
@ -107,7 +107,7 @@ public:
|
|||
|
||||
@see ApplicationCommandManager
|
||||
*/
|
||||
KeyPressMappingSet (ApplicationCommandManager* const commandManager) throw();
|
||||
KeyPressMappingSet (ApplicationCommandManager* commandManager) throw();
|
||||
|
||||
/** Creates an copy of a KeyPressMappingSet. */
|
||||
KeyPressMappingSet (const KeyPressMappingSet& other) throw();
|
||||
|
|
@ -123,7 +123,7 @@ public:
|
|||
|
||||
@param commandID the command's ID
|
||||
*/
|
||||
const Array <KeyPress> getKeyPressesAssignedToCommand (const CommandID commandID) const throw();
|
||||
const Array <KeyPress> getKeyPressesAssignedToCommand (CommandID commandID) const throw();
|
||||
|
||||
/** Assigns a keypress to a command.
|
||||
|
||||
|
|
@ -138,7 +138,7 @@ public:
|
|||
end of the list of keypresses; otherwise the new keypress will
|
||||
be inserted into the existing list at this index
|
||||
*/
|
||||
void addKeyPress (const CommandID commandID,
|
||||
void addKeyPress (CommandID commandID,
|
||||
const KeyPress& newKeyPress,
|
||||
int insertIndex = -1) throw();
|
||||
|
||||
|
|
@ -152,28 +152,28 @@ public:
|
|||
|
||||
@see resetToDefaultMappings
|
||||
*/
|
||||
void resetToDefaultMapping (const CommandID commandID) throw();
|
||||
void resetToDefaultMapping (CommandID commandID) throw();
|
||||
|
||||
/** Removes all keypresses that are assigned to any commands. */
|
||||
void clearAllKeyPresses() throw();
|
||||
|
||||
/** Removes all keypresses that are assigned to a particular command. */
|
||||
void clearAllKeyPresses (const CommandID commandID) throw();
|
||||
void clearAllKeyPresses (CommandID commandID) throw();
|
||||
|
||||
/** Removes one of the keypresses that are assigned to a command.
|
||||
|
||||
See the getKeyPressesAssignedToCommand() for the list of keypresses to
|
||||
which the keyPressIndex refers.
|
||||
*/
|
||||
void removeKeyPress (const CommandID commandID,
|
||||
const int keyPressIndex) throw();
|
||||
void removeKeyPress (CommandID commandID,
|
||||
int keyPressIndex) throw();
|
||||
|
||||
/** Removes a keypress from any command that it may be assigned to.
|
||||
*/
|
||||
void removeKeyPress (const KeyPress& keypress) throw();
|
||||
|
||||
/** Returns true if the given command is linked to this key. */
|
||||
bool containsMapping (const CommandID commandID,
|
||||
bool containsMapping (CommandID commandID,
|
||||
const KeyPress& keyPress) const throw();
|
||||
|
||||
//==============================================================================
|
||||
|
|
@ -218,13 +218,13 @@ public:
|
|||
|
||||
@see restoreFromXml
|
||||
*/
|
||||
XmlElement* createXml (const bool saveDifferencesFromDefaultSet) const;
|
||||
XmlElement* createXml (bool saveDifferencesFromDefaultSet) const;
|
||||
|
||||
//==============================================================================
|
||||
/** @internal */
|
||||
bool keyPressed (const KeyPress& key, Component* originatingComponent);
|
||||
/** @internal */
|
||||
bool keyStateChanged (const bool isKeyDown, Component* originatingComponent);
|
||||
bool keyStateChanged (bool isKeyDown, Component* originatingComponent);
|
||||
/** @internal */
|
||||
void globalFocusChanged (Component* focusedComponent);
|
||||
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ public:
|
|||
@see shiftModifier, ctrlModifier, altModifier, leftButtonModifier,
|
||||
rightButtonModifier, commandModifier, popupMenuClickModifier
|
||||
*/
|
||||
ModifierKeys (const int flags = 0) throw();
|
||||
ModifierKeys (int flags = 0) throw();
|
||||
|
||||
/** Creates a copy of another object. */
|
||||
ModifierKeys (const ModifierKeys& other) throw();
|
||||
|
|
|
|||
|
|
@ -53,42 +53,42 @@ public:
|
|||
|
||||
//==============================================================================
|
||||
/** Imposes a minimum width limit. */
|
||||
void setMinimumWidth (const int minimumWidth) throw();
|
||||
void setMinimumWidth (int minimumWidth) throw();
|
||||
|
||||
/** Returns the current minimum width. */
|
||||
int getMinimumWidth() const throw() { return minW; }
|
||||
|
||||
/** Imposes a maximum width limit. */
|
||||
void setMaximumWidth (const int maximumWidth) throw();
|
||||
void setMaximumWidth (int maximumWidth) throw();
|
||||
|
||||
/** Returns the current maximum width. */
|
||||
int getMaximumWidth() const throw() { return maxW; }
|
||||
|
||||
/** Imposes a minimum height limit. */
|
||||
void setMinimumHeight (const int minimumHeight) throw();
|
||||
void setMinimumHeight (int minimumHeight) throw();
|
||||
|
||||
/** Returns the current minimum height. */
|
||||
int getMinimumHeight() const throw() { return minH; }
|
||||
|
||||
/** Imposes a maximum height limit. */
|
||||
void setMaximumHeight (const int maximumHeight) throw();
|
||||
void setMaximumHeight (int maximumHeight) throw();
|
||||
|
||||
/** Returns the current maximum height. */
|
||||
int getMaximumHeight() const throw() { return maxH; }
|
||||
|
||||
/** Imposes a minimum width and height limit. */
|
||||
void setMinimumSize (const int minimumWidth,
|
||||
const int minimumHeight) throw();
|
||||
void setMinimumSize (int minimumWidth,
|
||||
int minimumHeight) throw();
|
||||
|
||||
/** Imposes a maximum width and height limit. */
|
||||
void setMaximumSize (const int maximumWidth,
|
||||
const int maximumHeight) throw();
|
||||
void setMaximumSize (int maximumWidth,
|
||||
int maximumHeight) throw();
|
||||
|
||||
/** Set all the maximum and minimum dimensions. */
|
||||
void setSizeLimits (const int minimumWidth,
|
||||
const int minimumHeight,
|
||||
const int maximumWidth,
|
||||
const int maximumHeight) throw();
|
||||
void setSizeLimits (int minimumWidth,
|
||||
int minimumHeight,
|
||||
int maximumWidth,
|
||||
int maximumHeight) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Sets the amount by which the component is allowed to go off-screen.
|
||||
|
|
@ -107,10 +107,10 @@ public:
|
|||
edge at all. So e.g. setting minimumWhenOffTheLeft to 0xffffff will mean that
|
||||
the component will bump into the left side of the screen and go no further.
|
||||
*/
|
||||
void setMinimumOnscreenAmounts (const int minimumWhenOffTheTop,
|
||||
const int minimumWhenOffTheLeft,
|
||||
const int minimumWhenOffTheBottom,
|
||||
const int minimumWhenOffTheRight) throw();
|
||||
void setMinimumOnscreenAmounts (int minimumWhenOffTheTop,
|
||||
int minimumWhenOffTheLeft,
|
||||
int minimumWhenOffTheBottom,
|
||||
int minimumWhenOffTheRight) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Specifies a width-to-height ratio that the resizer should always maintain.
|
||||
|
|
@ -120,7 +120,7 @@ public:
|
|||
|
||||
@see setResizeLimits
|
||||
*/
|
||||
void setFixedAspectRatio (const double widthOverHeight) throw();
|
||||
void setFixedAspectRatio (double widthOverHeight) throw();
|
||||
|
||||
/** Returns the aspect ratio that was set with setFixedAspectRatio().
|
||||
|
||||
|
|
@ -144,10 +144,10 @@ public:
|
|||
virtual void checkBounds (Rectangle<int>& bounds,
|
||||
const Rectangle<int>& previousBounds,
|
||||
const Rectangle<int>& limits,
|
||||
const bool isStretchingTop,
|
||||
const bool isStretchingLeft,
|
||||
const bool isStretchingBottom,
|
||||
const bool isStretchingRight);
|
||||
bool isStretchingTop,
|
||||
bool isStretchingLeft,
|
||||
bool isStretchingBottom,
|
||||
bool isStretchingRight);
|
||||
|
||||
/** This callback happens when the resizer is about to start dragging. */
|
||||
virtual void resizeStart();
|
||||
|
|
@ -158,10 +158,10 @@ public:
|
|||
/** Checks the given bounds, and then sets the component to the corrected size. */
|
||||
void setBoundsForComponent (Component* const component,
|
||||
const Rectangle<int>& bounds,
|
||||
const bool isStretchingTop,
|
||||
const bool isStretchingLeft,
|
||||
const bool isStretchingBottom,
|
||||
const bool isStretchingRight);
|
||||
bool isStretchingTop,
|
||||
bool isStretchingLeft,
|
||||
bool isStretchingBottom,
|
||||
bool isStretchingRight);
|
||||
|
||||
/** Performs a check on the current size of a component, and moves or resizes
|
||||
it if it fails the constraints.
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ class JUCE_API ComponentMovementWatcher : public ComponentListener
|
|||
public:
|
||||
//==============================================================================
|
||||
/** Creates a ComponentMovementWatcher to watch a given target component. */
|
||||
ComponentMovementWatcher (Component* const component);
|
||||
ComponentMovementWatcher (Component* component);
|
||||
|
||||
/** Destructor. */
|
||||
~ComponentMovementWatcher();
|
||||
|
|
|
|||
|
|
@ -88,8 +88,8 @@ public:
|
|||
@param isVertical whether it should be a vertical or horizontal bar
|
||||
@param buttonsAreVisible whether to show the up/down or left/right buttons
|
||||
*/
|
||||
ScrollBar (const bool isVertical,
|
||||
const bool buttonsAreVisible = true);
|
||||
ScrollBar (bool isVertical,
|
||||
bool buttonsAreVisible = true);
|
||||
|
||||
/** Destructor. */
|
||||
~ScrollBar();
|
||||
|
|
@ -105,10 +105,10 @@ public:
|
|||
|
||||
@param shouldBeVertical true makes it vertical; false makes it horizontal.
|
||||
*/
|
||||
void setOrientation (const bool shouldBeVertical) throw();
|
||||
void setOrientation (bool shouldBeVertical) throw();
|
||||
|
||||
/** Shows or hides the scrollbar's buttons. */
|
||||
void setButtonVisibility (const bool buttonsAreVisible);
|
||||
void setButtonVisibility (bool buttonsAreVisible);
|
||||
|
||||
/** Tells the scrollbar whether to make itself invisible when not needed.
|
||||
|
||||
|
|
@ -116,7 +116,7 @@ public:
|
|||
fills the whole of its range (i.e. when it can't be moved). Setting this
|
||||
value to false forces the bar to always be visible.
|
||||
*/
|
||||
void setAutoHide (const bool shouldHideWhenFullRange);
|
||||
void setAutoHide (bool shouldHideWhenFullRange);
|
||||
|
||||
//==============================================================================
|
||||
/** Sets the minimum and maximum values that the bar will move between.
|
||||
|
|
@ -126,8 +126,8 @@ public:
|
|||
|
||||
@see setCurrentRange
|
||||
*/
|
||||
void setRangeLimits (const double minimum,
|
||||
const double maximum) throw();
|
||||
void setRangeLimits (double minimum,
|
||||
double maximum) throw();
|
||||
|
||||
/** Returns the lower value that the thumb can be set to.
|
||||
|
||||
|
|
@ -193,7 +193,7 @@ public:
|
|||
The value here is in terms of the total range, and is added or subtracted
|
||||
from the thumb position when the user clicks an up/down (or left/right) button.
|
||||
*/
|
||||
void setSingleStepSize (const double newSingleStepSize) throw();
|
||||
void setSingleStepSize (double newSingleStepSize) throw();
|
||||
|
||||
/** Moves the scrollbar by a number of single-steps.
|
||||
|
||||
|
|
@ -203,7 +203,7 @@ public:
|
|||
A positive value here will move the bar down or to the right, a negative
|
||||
value moves it up or to the left.
|
||||
*/
|
||||
void moveScrollbarInSteps (const int howManySteps) throw();
|
||||
void moveScrollbarInSteps (int howManySteps) throw();
|
||||
|
||||
/** Moves the scroll bar up or down in pages.
|
||||
|
||||
|
|
@ -213,7 +213,7 @@ public:
|
|||
A positive value here will move the bar down or to the right, a negative
|
||||
value moves it up or to the left.
|
||||
*/
|
||||
void moveScrollbarInPages (const int howManyPages) throw();
|
||||
void moveScrollbarInPages (int howManyPages) throw();
|
||||
|
||||
/** Scrolls to the top (or left).
|
||||
|
||||
|
|
@ -234,9 +234,9 @@ public:
|
|||
|
||||
@see Button::setRepeatSpeed
|
||||
*/
|
||||
void setButtonRepeatSpeed (const int initialDelayInMillisecs,
|
||||
const int repeatDelayInMillisecs,
|
||||
const int minimumDelayInMillisecs = -1) throw();
|
||||
void setButtonRepeatSpeed (int initialDelayInMillisecs,
|
||||
int repeatDelayInMillisecs,
|
||||
int minimumDelayInMillisecs = -1) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** A set of colour IDs to use to change the colour of various aspects of the component.
|
||||
|
|
@ -255,10 +255,10 @@ public:
|
|||
|
||||
//==============================================================================
|
||||
/** Registers a listener that will be called when the scrollbar is moved. */
|
||||
void addListener (ScrollBarListener* const listener) throw();
|
||||
void addListener (ScrollBarListener* listener) throw();
|
||||
|
||||
/** Deregisters a previously-registered listener. */
|
||||
void removeListener (ScrollBarListener* const listener) throw();
|
||||
void removeListener (ScrollBarListener* listener) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** @internal */
|
||||
|
|
|
|||
|
|
@ -112,7 +112,7 @@ public:
|
|||
|
||||
@see setColour, Component::findColour, Component::setColour
|
||||
*/
|
||||
const Colour findColour (const int colourId) const throw();
|
||||
const Colour findColour (int colourId) const throw();
|
||||
|
||||
/** Registers a colour to be used for a particular purpose.
|
||||
|
||||
|
|
@ -120,12 +120,12 @@ public:
|
|||
|
||||
@see findColour, Component::findColour, Component::setColour
|
||||
*/
|
||||
void setColour (const int colourId, const Colour& colour) throw();
|
||||
void setColour (int colourId, const Colour& colour) throw();
|
||||
|
||||
/** Returns true if the specified colour ID has been explicitly set using the
|
||||
setColour() method.
|
||||
*/
|
||||
bool isColourSpecified (const int colourId) const throw();
|
||||
bool isColourSpecified (int colourId) const throw();
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
@ -172,10 +172,10 @@ public:
|
|||
virtual void drawTickBox (Graphics& g,
|
||||
Component& component,
|
||||
float x, float y, float w, float h,
|
||||
const bool ticked,
|
||||
const bool isEnabled,
|
||||
const bool isMouseOverButton,
|
||||
const bool isButtonDown);
|
||||
bool ticked,
|
||||
bool isEnabled,
|
||||
bool isMouseOverButton,
|
||||
bool isButtonDown);
|
||||
|
||||
//==============================================================================
|
||||
/* AlertWindow handling..
|
||||
|
|
@ -280,9 +280,9 @@ public:
|
|||
|
||||
//==============================================================================
|
||||
/** Returns a tick shape for use in yes/no boxes, etc. */
|
||||
virtual const Path getTickShape (const float height);
|
||||
virtual const Path getTickShape (float height);
|
||||
/** Returns a cross shape for use in yes/no boxes, etc. */
|
||||
virtual const Path getCrossShape (const float height);
|
||||
virtual const Path getCrossShape (float height);
|
||||
|
||||
//==============================================================================
|
||||
/** Draws the + or - box in a treeview. */
|
||||
|
|
@ -306,9 +306,9 @@ public:
|
|||
const String& filename, Image* icon,
|
||||
const String& fileSizeDescription,
|
||||
const String& fileTimeDescription,
|
||||
const bool isDirectory,
|
||||
const bool isItemSelected,
|
||||
const int itemIndex);
|
||||
bool isDirectory,
|
||||
bool isItemSelected,
|
||||
int itemIndex);
|
||||
|
||||
virtual Button* createFileBrowserGoUpButton();
|
||||
|
||||
|
|
@ -331,11 +331,11 @@ public:
|
|||
/** Draws one of the items in a popup menu. */
|
||||
virtual void drawPopupMenuItem (Graphics& g,
|
||||
int width, int height,
|
||||
const bool isSeparator,
|
||||
const bool isActive,
|
||||
const bool isHighlighted,
|
||||
const bool isTicked,
|
||||
const bool hasSubMenu,
|
||||
bool isSeparator,
|
||||
bool isActive,
|
||||
bool isHighlighted,
|
||||
bool isTicked,
|
||||
bool hasSubMenu,
|
||||
const String& text,
|
||||
const String& shortcutKeyText,
|
||||
Image* image,
|
||||
|
|
@ -350,7 +350,7 @@ public:
|
|||
|
||||
/** Finds the best size for an item in a popup menu. */
|
||||
virtual void getIdealPopupMenuItemSize (const String& text,
|
||||
const bool isSeparator,
|
||||
bool isSeparator,
|
||||
int standardMenuItemHeight,
|
||||
int& idealWidth,
|
||||
int& idealHeight);
|
||||
|
|
@ -376,7 +376,7 @@ public:
|
|||
|
||||
//==============================================================================
|
||||
virtual void drawComboBox (Graphics& g, int width, int height,
|
||||
const bool isButtonDown,
|
||||
bool isButtonDown,
|
||||
int buttonX, int buttonY,
|
||||
int buttonW, int buttonH,
|
||||
ComboBox& box);
|
||||
|
|
@ -424,11 +424,11 @@ public:
|
|||
int x, int y,
|
||||
int width, int height,
|
||||
float sliderPosProportional,
|
||||
const float rotaryStartAngle,
|
||||
const float rotaryEndAngle,
|
||||
float rotaryStartAngle,
|
||||
float rotaryEndAngle,
|
||||
Slider& slider);
|
||||
|
||||
virtual Button* createSliderButton (const bool isIncrement);
|
||||
virtual Button* createSliderButton (bool isIncrement);
|
||||
virtual Label* createSliderTextBox (Slider& slider);
|
||||
|
||||
virtual ImageEffectFilter* getSliderEffect();
|
||||
|
|
@ -506,9 +506,9 @@ public:
|
|||
const String& text,
|
||||
Button& button,
|
||||
TabbedButtonBar::Orientation orientation,
|
||||
const bool isMouseOver,
|
||||
const bool isMouseDown,
|
||||
const bool isFrontTab);
|
||||
bool isMouseOver,
|
||||
bool isMouseDown,
|
||||
bool isFrontTab);
|
||||
|
||||
virtual void fillTabButtonShape (Graphics& g,
|
||||
const Path& path,
|
||||
|
|
@ -517,9 +517,9 @@ public:
|
|||
const String& text,
|
||||
Button& button,
|
||||
TabbedButtonBar::Orientation orientation,
|
||||
const bool isMouseOver,
|
||||
const bool isMouseDown,
|
||||
const bool isFrontTab);
|
||||
bool isMouseOver,
|
||||
bool isMouseDown,
|
||||
bool isFrontTab);
|
||||
|
||||
virtual void drawTabButtonText (Graphics& g,
|
||||
int x, int y, int w, int h,
|
||||
|
|
@ -528,9 +528,9 @@ public:
|
|||
const String& text,
|
||||
Button& button,
|
||||
TabbedButtonBar::Orientation orientation,
|
||||
const bool isMouseOver,
|
||||
const bool isMouseDown,
|
||||
const bool isFrontTab);
|
||||
bool isMouseOver,
|
||||
bool isMouseDown,
|
||||
bool isFrontTab);
|
||||
|
||||
virtual int getTabButtonOverlap (int tabDepth);
|
||||
virtual int getTabButtonSpaceAroundImage();
|
||||
|
|
@ -547,9 +547,9 @@ public:
|
|||
const String& text,
|
||||
Button& button,
|
||||
TabbedButtonBar::Orientation orientation,
|
||||
const bool isMouseOver,
|
||||
const bool isMouseDown,
|
||||
const bool isFrontTab);
|
||||
bool isMouseOver,
|
||||
bool isMouseDown,
|
||||
bool isFrontTab);
|
||||
|
||||
virtual void drawTabAreaBehindFrontButton (Graphics& g,
|
||||
int w, int h,
|
||||
|
|
@ -610,26 +610,26 @@ public:
|
|||
//==============================================================================
|
||||
/** Utility function to draw a shiny, glassy circle (for round LED-type buttons). */
|
||||
static void drawGlassSphere (Graphics& g,
|
||||
const float x, const float y,
|
||||
const float diameter,
|
||||
float x, float y,
|
||||
float diameter,
|
||||
const Colour& colour,
|
||||
const float outlineThickness) throw();
|
||||
float outlineThickness) throw();
|
||||
|
||||
static void drawGlassPointer (Graphics& g,
|
||||
const float x, const float y,
|
||||
const float diameter,
|
||||
const Colour& colour, const float outlineThickness,
|
||||
const int direction) throw();
|
||||
float x, float y,
|
||||
float diameter,
|
||||
const Colour& colour, float outlineThickness,
|
||||
int direction) throw();
|
||||
|
||||
/** Utility function to draw a shiny, glassy oblong (for text buttons). */
|
||||
static void drawGlassLozenge (Graphics& g,
|
||||
const float x, const float y,
|
||||
const float width, const float height,
|
||||
float x, float y,
|
||||
float width, float height,
|
||||
const Colour& colour,
|
||||
const float outlineThickness,
|
||||
const float cornerSize,
|
||||
const bool flatOnLeft, const bool flatOnRight,
|
||||
const bool flatOnTop, const bool flatOnBottom) throw();
|
||||
float outlineThickness,
|
||||
float cornerSize,
|
||||
bool flatOnLeft, bool flatOnRight,
|
||||
bool flatOnTop, bool flatOnBottom) throw();
|
||||
|
||||
//==============================================================================
|
||||
juce_UseDebuggingNewOperator
|
||||
|
|
@ -648,11 +648,11 @@ private:
|
|||
void drawShinyButtonShape (Graphics& g,
|
||||
float x, float y, float w, float h, float maxCornerSize,
|
||||
const Colour& baseColour,
|
||||
const float strokeWidth,
|
||||
const bool flatOnLeft,
|
||||
const bool flatOnRight,
|
||||
const bool flatOnTop,
|
||||
const bool flatOnBottom) throw();
|
||||
float strokeWidth,
|
||||
bool flatOnLeft,
|
||||
bool flatOnRight,
|
||||
bool flatOnTop,
|
||||
bool flatOnBottom) throw();
|
||||
|
||||
LookAndFeel (const LookAndFeel&);
|
||||
LookAndFeel& operator= (const LookAndFeel&);
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ public:
|
|||
pass 0 into this if you like, and set the model later
|
||||
using the setModel() method
|
||||
*/
|
||||
MenuBarComponent (MenuBarModel* const model);
|
||||
MenuBarComponent (MenuBarModel* model);
|
||||
|
||||
/** Destructor. */
|
||||
~MenuBarComponent();
|
||||
|
|
@ -58,7 +58,7 @@ public:
|
|||
This can be 0, in which case the bar will be empty. Don't delete the object
|
||||
that is passed-in while it's still being used by this MenuBar.
|
||||
*/
|
||||
void setModel (MenuBarModel* const newModel);
|
||||
void setModel (MenuBarModel* newModel);
|
||||
|
||||
//==============================================================================
|
||||
/** Pops up one of the menu items.
|
||||
|
|
@ -66,7 +66,7 @@ public:
|
|||
This lets you manually open one of the menus - it could be triggered by a
|
||||
key shortcut, for example.
|
||||
*/
|
||||
void showMenu (const int menuIndex);
|
||||
void showMenu (int menuIndex);
|
||||
|
||||
//==============================================================================
|
||||
/** @internal */
|
||||
|
|
@ -112,7 +112,7 @@ private:
|
|||
ScopedPointer <Component> currentPopup;
|
||||
|
||||
int getItemAt (int x, int y);
|
||||
void updateItemUnderMouse (const int x, const int y);
|
||||
void updateItemUnderMouse (int x, int y);
|
||||
void hideCurrentMenu();
|
||||
void timerCallback();
|
||||
void repaintMenuItem (int index);
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ public:
|
|||
This will also allow it to flash a menu name when a command from that menu
|
||||
is invoked using a keystroke.
|
||||
*/
|
||||
void setApplicationCommandManagerToWatch (ApplicationCommandManager* const manager) throw();
|
||||
void setApplicationCommandManagerToWatch (ApplicationCommandManager* manager) throw();
|
||||
|
||||
/** Registers a listener for callbacks when the menu items in this model change.
|
||||
|
||||
|
|
@ -104,13 +104,13 @@ public:
|
|||
|
||||
@see removeListener
|
||||
*/
|
||||
void addListener (MenuBarModelListener* const listenerToAdd) throw();
|
||||
void addListener (MenuBarModelListener* listenerToAdd) throw();
|
||||
|
||||
/** Removes a listener.
|
||||
|
||||
@see addListener
|
||||
*/
|
||||
void removeListener (MenuBarModelListener* const listenerToRemove) throw();
|
||||
void removeListener (MenuBarModelListener* listenerToRemove) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** This method must return a list of the names of the menus. */
|
||||
|
|
|
|||
|
|
@ -115,11 +115,11 @@ public:
|
|||
|
||||
@see addSeparator, addColouredItem, addCustomItem, addSubMenu
|
||||
*/
|
||||
void addItem (const int itemResultId,
|
||||
void addItem (int itemResultId,
|
||||
const String& itemText,
|
||||
const bool isActive = true,
|
||||
const bool isTicked = false,
|
||||
const Image* const iconToUse = 0);
|
||||
bool isActive = true,
|
||||
bool isTicked = false,
|
||||
const Image* iconToUse = 0);
|
||||
|
||||
/** Adds an item that represents one of the commands in a command manager object.
|
||||
|
||||
|
|
@ -130,7 +130,7 @@ public:
|
|||
the command's registered name
|
||||
*/
|
||||
void addCommandItem (ApplicationCommandManager* commandManager,
|
||||
const int commandID,
|
||||
int commandID,
|
||||
const String& displayName = String::empty);
|
||||
|
||||
|
||||
|
|
@ -140,12 +140,12 @@ public:
|
|||
text, which will override the default colours that are used by the
|
||||
current look-and-feel. See addItem() for a description of the parameters.
|
||||
*/
|
||||
void addColouredItem (const int itemResultId,
|
||||
void addColouredItem (int itemResultId,
|
||||
const String& itemText,
|
||||
const Colour& itemTextColour,
|
||||
const bool isActive = true,
|
||||
const bool isTicked = false,
|
||||
const Image* const iconToUse = 0);
|
||||
bool isActive = true,
|
||||
bool isTicked = false,
|
||||
const Image* iconToUse = 0);
|
||||
|
||||
/** Appends a custom menu item.
|
||||
|
||||
|
|
@ -154,8 +154,7 @@ public:
|
|||
|
||||
@see PopupMenuCustomComponent
|
||||
*/
|
||||
void addCustomItem (const int itemResultId,
|
||||
PopupMenuCustomComponent* const customComponent);
|
||||
void addCustomItem (int itemResultId, PopupMenuCustomComponent* customComponent);
|
||||
|
||||
/** Appends a custom menu item that can't be used to trigger a result.
|
||||
|
||||
|
|
@ -172,10 +171,10 @@ public:
|
|||
|
||||
@see PopupMenuCustomComponent
|
||||
*/
|
||||
void addCustomItem (const int itemResultId,
|
||||
void addCustomItem (int itemResultId,
|
||||
Component* customComponent,
|
||||
int idealWidth, int idealHeight,
|
||||
const bool triggerMenuItemAutomaticallyWhenClicked);
|
||||
bool triggerMenuItemAutomaticallyWhenClicked);
|
||||
|
||||
/** Appends a sub-menu.
|
||||
|
||||
|
|
@ -183,9 +182,9 @@ public:
|
|||
*/
|
||||
void addSubMenu (const String& subMenuName,
|
||||
const PopupMenu& subMenu,
|
||||
const bool isActive = true,
|
||||
Image* const iconToUse = 0,
|
||||
const bool isTicked = false);
|
||||
bool isActive = true,
|
||||
Image* iconToUse = 0,
|
||||
bool isTicked = false);
|
||||
|
||||
/** Appends a separator to the menu, to help break it up into sections.
|
||||
|
||||
|
|
@ -210,7 +209,7 @@ public:
|
|||
int getNumItems() const throw();
|
||||
|
||||
/** Returns true if the menu contains a command item that triggers the given command. */
|
||||
bool containsCommandItem (const int commandID) const;
|
||||
bool containsCommandItem (int commandID) const;
|
||||
|
||||
/** Returns true if the menu contains any items that can be used. */
|
||||
bool containsAnyActiveItems() const throw();
|
||||
|
|
@ -243,10 +242,10 @@ public:
|
|||
height for menu items (apart from custom items)
|
||||
@see showAt
|
||||
*/
|
||||
int show (const int itemIdThatMustBeVisible = 0,
|
||||
const int minimumWidth = 0,
|
||||
const int maximumNumColumns = 0,
|
||||
const int standardItemHeight = 0);
|
||||
int show (int itemIdThatMustBeVisible = 0,
|
||||
int minimumWidth = 0,
|
||||
int maximumNumColumns = 0,
|
||||
int standardItemHeight = 0);
|
||||
|
||||
|
||||
/** Displays the menu at a specific location.
|
||||
|
|
@ -260,12 +259,12 @@ public:
|
|||
|
||||
@see show()
|
||||
*/
|
||||
int showAt (const int screenX,
|
||||
const int screenY,
|
||||
const int itemIdThatMustBeVisible = 0,
|
||||
const int minimumWidth = 0,
|
||||
const int maximumNumColumns = 0,
|
||||
const int standardItemHeight = 0);
|
||||
int showAt (int screenX,
|
||||
int screenY,
|
||||
int itemIdThatMustBeVisible = 0,
|
||||
int minimumWidth = 0,
|
||||
int maximumNumColumns = 0,
|
||||
int standardItemHeight = 0);
|
||||
|
||||
/** Displays the menu as if it's attached to a component such as a button.
|
||||
|
||||
|
|
@ -274,10 +273,10 @@ public:
|
|||
things like buttons that trigger a pop-up menu.
|
||||
*/
|
||||
int showAt (Component* componentToAttachTo,
|
||||
const int itemIdThatMustBeVisible = 0,
|
||||
const int minimumWidth = 0,
|
||||
const int maximumNumColumns = 0,
|
||||
const int standardItemHeight = 0);
|
||||
int itemIdThatMustBeVisible = 0,
|
||||
int minimumWidth = 0,
|
||||
int maximumNumColumns = 0,
|
||||
int standardItemHeight = 0);
|
||||
|
||||
//==============================================================================
|
||||
/** Closes any menus that are currently open.
|
||||
|
|
@ -295,7 +294,7 @@ public:
|
|||
This can be called before show() if you need a customised menu. Be careful
|
||||
not to delete the LookAndFeel object before the menu has been deleted.
|
||||
*/
|
||||
void setLookAndFeel (LookAndFeel* const newLookAndFeel);
|
||||
void setLookAndFeel (LookAndFeel* newLookAndFeel);
|
||||
|
||||
//==============================================================================
|
||||
/** A set of colour IDs to use to change the colour of various aspects of the menu.
|
||||
|
|
@ -393,24 +392,24 @@ private:
|
|||
|
||||
void addSeparatorIfPending();
|
||||
|
||||
int showMenu (const int x, const int y, const int w, const int h,
|
||||
const int itemIdThatMustBeVisible,
|
||||
const int minimumWidth,
|
||||
const int maximumNumColumns,
|
||||
const int standardItemHeight,
|
||||
const bool alignToRectangle,
|
||||
Component* const componentAttachedTo);
|
||||
int showMenu (int x, int y, int w, int h,
|
||||
int itemIdThatMustBeVisible,
|
||||
int minimumWidth,
|
||||
int maximumNumColumns,
|
||||
int standardItemHeight,
|
||||
bool alignToRectangle,
|
||||
Component* componentAttachedTo);
|
||||
|
||||
friend class MenuBarComponent;
|
||||
Component* createMenuComponent (const int x, const int y, const int w, const int h,
|
||||
const int itemIdThatMustBeVisible,
|
||||
const int minimumWidth,
|
||||
const int maximumNumColumns,
|
||||
const int standardItemHeight,
|
||||
const bool alignToRectangle,
|
||||
Component* createMenuComponent (int x, int y, int w, int h,
|
||||
int itemIdThatMustBeVisible,
|
||||
int minimumWidth,
|
||||
int maximumNumColumns,
|
||||
int standardItemHeight,
|
||||
bool alignToRectangle,
|
||||
Component* menuBarComponent,
|
||||
ApplicationCommandManager** managerOfChosenCommand,
|
||||
Component* const componentAttachedTo);
|
||||
Component* componentAttachedTo);
|
||||
};
|
||||
|
||||
#endif // __JUCE_POPUPMENU_JUCEHEADER__
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ protected:
|
|||
a click on this component and use that to trigger it. If it's false, then it's
|
||||
up to your class to manually trigger the item if it wants to.
|
||||
*/
|
||||
PopupMenuCustomComponent (const bool isTriggeredAutomatically = true);
|
||||
PopupMenuCustomComponent (bool isTriggeredAutomatically = true);
|
||||
|
||||
|
||||
private:
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ public:
|
|||
void startDragging (const String& sourceDescription,
|
||||
Component* sourceComponent,
|
||||
Image* dragImage = 0,
|
||||
const bool allowDraggingToOtherJuceWindows = false,
|
||||
bool allowDraggingToOtherJuceWindows = false,
|
||||
const Point<int>* imageOffsetFromMouse = 0);
|
||||
|
||||
/** Returns true if something is currently being dragged. */
|
||||
|
|
@ -137,7 +137,7 @@ public:
|
|||
was interrupted
|
||||
@see performExternalDragDropOfText
|
||||
*/
|
||||
static bool performExternalDragDropOfFiles (const StringArray& files, const bool canMoveFiles);
|
||||
static bool performExternalDragDropOfFiles (const StringArray& files, bool canMoveFiles);
|
||||
|
||||
/** This performs a synchronous drag-and-drop of a block of text to some external
|
||||
application.
|
||||
|
|
|
|||
|
|
@ -76,8 +76,7 @@ public:
|
|||
*/
|
||||
virtual void itemDragEnter (const String& sourceDescription,
|
||||
Component* sourceComponent,
|
||||
int x,
|
||||
int y);
|
||||
int x, int y);
|
||||
|
||||
/** Callback to indicate that the user is dragging something over this component.
|
||||
|
||||
|
|
@ -92,8 +91,7 @@ public:
|
|||
*/
|
||||
virtual void itemDragMove (const String& sourceDescription,
|
||||
Component* sourceComponent,
|
||||
int x,
|
||||
int y);
|
||||
int x, int y);
|
||||
|
||||
/** Callback to indicate that something has been dragged off the edge of this component.
|
||||
|
||||
|
|
@ -125,8 +123,7 @@ public:
|
|||
*/
|
||||
virtual void itemDropped (const String& sourceDescription,
|
||||
Component* sourceComponent,
|
||||
int x,
|
||||
int y) = 0;
|
||||
int x, int y) = 0;
|
||||
|
||||
/** Overriding this allows the target to tell the drag container whether to
|
||||
draw the drag image while the cursor is over it.
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ public:
|
|||
MouseCursor() throw();
|
||||
|
||||
/** Creates one of the standard mouse cursor */
|
||||
MouseCursor (const StandardCursorType type) throw();
|
||||
MouseCursor (StandardCursorType type) throw();
|
||||
|
||||
/** Creates a custom cursor from an image.
|
||||
|
||||
|
|
@ -89,9 +89,7 @@ public:
|
|||
@param hotSpotX the x position of the cursor's hotspot within the image
|
||||
@param hotSpotY the y position of the cursor's hotspot within the image
|
||||
*/
|
||||
MouseCursor (const Image& image,
|
||||
const int hotSpotX,
|
||||
const int hotSpotY) throw();
|
||||
MouseCursor (const Image& image, int hotSpotX, int hotSpotY) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** Creates a copy of another cursor object. */
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ public:
|
|||
|
||||
//==============================================================================
|
||||
/** Called to change the state of the boolean value. */
|
||||
virtual void setState (const bool newState);
|
||||
virtual void setState (bool newState);
|
||||
|
||||
/** Must return the current value of the property. */
|
||||
virtual bool getState() const;
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ public:
|
|||
@param triggerOnMouseDown this is passed to the Button::setTriggeredOnMouseDown() method
|
||||
*/
|
||||
ButtonPropertyComponent (const String& propertyName,
|
||||
const bool triggerOnMouseDown);
|
||||
bool triggerOnMouseDown);
|
||||
|
||||
/** Destructor. */
|
||||
~ButtonPropertyComponent();
|
||||
|
|
|
|||
|
|
@ -88,7 +88,7 @@ public:
|
|||
represents. The index is the index of the chosen item in the choices
|
||||
StringArray.
|
||||
*/
|
||||
virtual void setIndex (const int newIndex);
|
||||
virtual void setIndex (int newIndex);
|
||||
|
||||
/** Returns the index of the item that should currently be shown.
|
||||
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ public:
|
|||
preferredHeight member variable.
|
||||
*/
|
||||
PropertyComponent (const String& propertyName,
|
||||
const int preferredHeight = 25);
|
||||
int preferredHeight = 25);
|
||||
|
||||
/** Destructor. */
|
||||
~PropertyComponent();
|
||||
|
|
|
|||
|
|
@ -80,7 +80,7 @@ public:
|
|||
*/
|
||||
void addSection (const String& sectionTitle,
|
||||
const Array <PropertyComponent*>& newPropertyComponents,
|
||||
const bool shouldSectionInitiallyBeOpen = true);
|
||||
bool shouldSectionInitiallyBeOpen = true);
|
||||
|
||||
/** Calls the refresh() method of all PropertyComponents in the panel */
|
||||
void refreshAll() const;
|
||||
|
|
@ -96,19 +96,19 @@ public:
|
|||
|
||||
The index is from 0 up to the number of items returned by getSectionNames().
|
||||
*/
|
||||
bool isSectionOpen (const int sectionIndex) const;
|
||||
bool isSectionOpen (int sectionIndex) const;
|
||||
|
||||
/** Opens or closes one of the sections.
|
||||
|
||||
The index is from 0 up to the number of items returned by getSectionNames().
|
||||
*/
|
||||
void setSectionOpen (const int sectionIndex, const bool shouldBeOpen);
|
||||
void setSectionOpen (int sectionIndex, bool shouldBeOpen);
|
||||
|
||||
/** Enables or disables one of the sections.
|
||||
|
||||
The index is from 0 up to the number of items returned by getSectionNames().
|
||||
*/
|
||||
void setSectionEnabled (const int sectionIndex, const bool shouldBeEnabled);
|
||||
void setSectionEnabled (int sectionIndex, bool shouldBeEnabled);
|
||||
|
||||
//==============================================================================
|
||||
/** Saves the current state of open/closed sections so it can be restored later.
|
||||
|
|
@ -157,7 +157,7 @@ private:
|
|||
String messageWhenEmpty;
|
||||
|
||||
void updatePropHolderLayout() const;
|
||||
void updatePropHolderLayout (const int width) const;
|
||||
void updatePropHolderLayout (int width) const;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ void SliderPropertyComponent::setValue (const double /*newValue*/)
|
|||
{
|
||||
}
|
||||
|
||||
const double SliderPropertyComponent::getValue() const
|
||||
double SliderPropertyComponent::getValue() const
|
||||
{
|
||||
return slider->getValue();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -49,10 +49,10 @@ protected:
|
|||
access the slider member variable and change it directly.
|
||||
*/
|
||||
SliderPropertyComponent (const String& propertyName,
|
||||
const double rangeMin,
|
||||
const double rangeMax,
|
||||
const double interval,
|
||||
const double skewFactor = 1.0);
|
||||
double rangeMin,
|
||||
double rangeMax,
|
||||
double interval,
|
||||
double skewFactor = 1.0);
|
||||
|
||||
public:
|
||||
//==============================================================================
|
||||
|
|
@ -65,10 +65,10 @@ public:
|
|||
*/
|
||||
SliderPropertyComponent (Value& valueToControl,
|
||||
const String& propertyName,
|
||||
const double rangeMin,
|
||||
const double rangeMax,
|
||||
const double interval,
|
||||
const double skewFactor = 1.0);
|
||||
double rangeMin,
|
||||
double rangeMax,
|
||||
double interval,
|
||||
double skewFactor = 1.0);
|
||||
|
||||
/** Destructor. */
|
||||
~SliderPropertyComponent();
|
||||
|
|
@ -80,10 +80,10 @@ public:
|
|||
Your subclass must use this method to update whatever item this property
|
||||
represents.
|
||||
*/
|
||||
virtual void setValue (const double newValue);
|
||||
virtual void setValue (double newValue);
|
||||
|
||||
/** Returns the value that the slider should show. */
|
||||
virtual const double getValue() const;
|
||||
virtual double getValue() const;
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
|
|||
|
|
@ -48,8 +48,8 @@ protected:
|
|||
@see TextEditor
|
||||
*/
|
||||
TextPropertyComponent (const String& propertyName,
|
||||
const int maxNumChars,
|
||||
const bool isMultiLine);
|
||||
int maxNumChars,
|
||||
bool isMultiLine);
|
||||
|
||||
public:
|
||||
/** Creates a text property component.
|
||||
|
|
@ -61,8 +61,8 @@ public:
|
|||
*/
|
||||
TextPropertyComponent (const Value& valueToControl,
|
||||
const String& propertyName,
|
||||
const int maxNumChars,
|
||||
const bool isMultiLine);
|
||||
int maxNumChars,
|
||||
bool isMultiLine);
|
||||
|
||||
/** Destructor. */
|
||||
~TextPropertyComponent();
|
||||
|
|
@ -91,7 +91,7 @@ public:
|
|||
private:
|
||||
Label* textEditor;
|
||||
|
||||
void createEditor (const int maxNumChars, const bool isMultiLine);
|
||||
void createEditor (int maxNumChars, bool isMultiLine);
|
||||
|
||||
TextPropertyComponent (const TextPropertyComponent&);
|
||||
TextPropertyComponent& operator= (const TextPropertyComponent&);
|
||||
|
|
|
|||
|
|
@ -101,7 +101,7 @@ public:
|
|||
|
||||
/** Set this to false to stop mouse events being allowed through to the control.
|
||||
*/
|
||||
void setMouseEventsAllowed (const bool eventsCanReachControl);
|
||||
void setMouseEventsAllowed (bool eventsCanReachControl);
|
||||
|
||||
/** Returns true if mouse events are allowed to get through to the control.
|
||||
*/
|
||||
|
|
@ -125,7 +125,7 @@ private:
|
|||
ActiveXControlComponent& operator= (const ActiveXControlComponent&);
|
||||
|
||||
void setControlBounds (const Rectangle<int>& bounds) const;
|
||||
void setControlVisible (const bool b) const;
|
||||
void setControlVisible (bool b) const;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -86,7 +86,7 @@ public:
|
|||
|
||||
@see BubblePlacement
|
||||
*/
|
||||
void setAllowedPlacement (const int newPlacement);
|
||||
void setAllowedPlacement (int newPlacement);
|
||||
|
||||
//==============================================================================
|
||||
/** Moves and resizes the bubble to point at a given component.
|
||||
|
|
@ -111,8 +111,8 @@ public:
|
|||
on where there's the most space, honouring any restrictions that were set
|
||||
with setAllowedPlacement().
|
||||
*/
|
||||
void setPosition (const int arrowTipX,
|
||||
const int arrowTipY);
|
||||
void setPosition (int arrowTipX,
|
||||
int arrowTipY);
|
||||
|
||||
/** Moves and resizes the bubble to point at a given rectangle.
|
||||
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ public:
|
|||
also delete itself), or you can reuse it somewhere else by calling
|
||||
showAt() again.
|
||||
*/
|
||||
BubbleMessageComponent (const int fadeOutLengthMs = 150);
|
||||
BubbleMessageComponent (int fadeOutLengthMs = 150);
|
||||
|
||||
/** Destructor. */
|
||||
~BubbleMessageComponent();
|
||||
|
|
@ -82,9 +82,9 @@ public:
|
|||
*/
|
||||
void showAt (int x, int y,
|
||||
const String& message,
|
||||
const int numMillisecondsBeforeRemoving,
|
||||
const bool removeWhenMouseClicked = true,
|
||||
const bool deleteSelfAfterUse = false);
|
||||
int numMillisecondsBeforeRemoving,
|
||||
bool removeWhenMouseClicked = true,
|
||||
bool deleteSelfAfterUse = false);
|
||||
|
||||
/** Shows a message bubble next to a particular component.
|
||||
|
||||
|
|
@ -103,11 +103,11 @@ public:
|
|||
@param deleteSelfAfterUse if true, then the component will delete itself after
|
||||
it becomes invisible
|
||||
*/
|
||||
void showAt (Component* const component,
|
||||
void showAt (Component* component,
|
||||
const String& message,
|
||||
const int numMillisecondsBeforeRemoving,
|
||||
const bool removeWhenMouseClicked = true,
|
||||
const bool deleteSelfAfterUse = false);
|
||||
int numMillisecondsBeforeRemoving,
|
||||
bool removeWhenMouseClicked = true,
|
||||
bool deleteSelfAfterUse = false);
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
@ -126,9 +126,9 @@ private:
|
|||
int64 expiryTime;
|
||||
bool deleteAfterUse;
|
||||
|
||||
void init (const int numMillisecondsBeforeRemoving,
|
||||
const bool removeWhenMouseClicked,
|
||||
const bool deleteSelfAfterUse);
|
||||
void init (int numMillisecondsBeforeRemoving,
|
||||
bool removeWhenMouseClicked,
|
||||
bool deleteSelfAfterUse);
|
||||
|
||||
BubbleMessageComponent (const BubbleMessageComponent&);
|
||||
BubbleMessageComponent& operator= (const BubbleMessageComponent&);
|
||||
|
|
|
|||
|
|
@ -66,9 +66,9 @@ public:
|
|||
gapAroundColourSpaceComponent indicates how much of a gap to put around the
|
||||
colourspace and hue selector components.
|
||||
*/
|
||||
ColourSelector (const int sectionsToShow = (showAlphaChannel | showColourAtTop | showSliders | showColourspace),
|
||||
const int edgeGap = 4,
|
||||
const int gapAroundColourSpaceComponent = 7);
|
||||
ColourSelector (int sectionsToShow = (showAlphaChannel | showColourAtTop | showSliders | showColourspace),
|
||||
int edgeGap = 4,
|
||||
int gapAroundColourSpaceComponent = 7);
|
||||
|
||||
/** Destructor. */
|
||||
~ColourSelector();
|
||||
|
|
@ -104,7 +104,7 @@ public:
|
|||
setSwatchColour(), to return the number of colours you want, and to set and retrieve
|
||||
their values.
|
||||
*/
|
||||
virtual const Colour getSwatchColour (const int index) const;
|
||||
virtual const Colour getSwatchColour (int index) const;
|
||||
|
||||
/** Called by the selector when the user puts a new colour into one of the swatches.
|
||||
|
||||
|
|
@ -114,7 +114,7 @@ public:
|
|||
setSwatchColour(), to return the number of colours you want, and to set and retrieve
|
||||
their values.
|
||||
*/
|
||||
virtual void setSwatchColour (const int index, const Colour& newColour) const;
|
||||
virtual void setSwatchColour (int index, const Colour& newColour) const;
|
||||
|
||||
|
||||
//==============================================================================
|
||||
|
|
@ -162,7 +162,7 @@ private:
|
|||
// this constructor is here temporarily to prevent old code compiling, because the parameters
|
||||
// have changed - if you get an error here, update your code to use the new constructor instead..
|
||||
// (xxx - note to self: remember to remove this at some point in the future)
|
||||
ColourSelector (const bool);
|
||||
ColourSelector (bool);
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -54,10 +54,10 @@ public:
|
|||
@param yOffset the vertical displacement of the shadow, in pixels
|
||||
@param blurRadius the radius of the blur to use for creating the shadow
|
||||
*/
|
||||
DropShadower (const float alpha = 0.5f,
|
||||
const int xOffset = 1,
|
||||
const int yOffset = 5,
|
||||
const float blurRadius = 10.0f);
|
||||
DropShadower (float alpha = 0.5f,
|
||||
int xOffset = 1,
|
||||
int yOffset = 5,
|
||||
float blurRadius = 10.0f);
|
||||
|
||||
/** Destructor. */
|
||||
virtual ~DropShadower();
|
||||
|
|
|
|||
|
|
@ -60,8 +60,8 @@ public:
|
|||
be deleted when this component is deleted. If false,
|
||||
it's the caller's responsibility to delete it later.
|
||||
*/
|
||||
MagnifierComponent (Component* const contentComponent,
|
||||
const bool deleteContentCompWhenNoLongerNeeded);
|
||||
MagnifierComponent (Component* contentComponent,
|
||||
bool deleteContentCompWhenNoLongerNeeded);
|
||||
|
||||
/** Destructor. */
|
||||
~MagnifierComponent();
|
||||
|
|
@ -114,7 +114,7 @@ private:
|
|||
void mouseWheelMove (const MouseEvent& e, float, float);
|
||||
|
||||
void passOnMouseEventToPeer (const MouseEvent& e);
|
||||
int scaleInt (const int n) const;
|
||||
int scaleInt (int n) const;
|
||||
|
||||
MagnifierComponent (const MagnifierComponent&);
|
||||
MagnifierComponent& operator= (const MagnifierComponent&);
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ public:
|
|||
@param orientation whether the keyboard is horizonal or vertical
|
||||
*/
|
||||
MidiKeyboardComponent (MidiKeyboardState& state,
|
||||
const Orientation orientation);
|
||||
Orientation orientation);
|
||||
|
||||
/** Destructor. */
|
||||
~MidiKeyboardComponent();
|
||||
|
|
@ -89,7 +89,7 @@ public:
|
|||
|
||||
@see setMidiChannel
|
||||
*/
|
||||
void setVelocity (const float velocity, const bool useMousePositionForVelocity);
|
||||
void setVelocity (float velocity, bool useMousePositionForVelocity);
|
||||
|
||||
/** Changes the midi channel number that will be used for events triggered by clicking
|
||||
on the component.
|
||||
|
|
@ -102,7 +102,7 @@ public:
|
|||
|
||||
@see setVelocity
|
||||
*/
|
||||
void setMidiChannel (const int midiChannelNumber);
|
||||
void setMidiChannel (int midiChannelNumber);
|
||||
|
||||
/** Returns the midi channel that the keyboard is using for midi messages.
|
||||
|
||||
|
|
@ -122,7 +122,7 @@ public:
|
|||
|
||||
@see setMidiChannel
|
||||
*/
|
||||
void setMidiChannelsToDisplay (const int midiChannelMask);
|
||||
void setMidiChannelsToDisplay (int midiChannelMask);
|
||||
|
||||
/** Returns the current set of midi channels represented by the component.
|
||||
|
||||
|
|
@ -132,13 +132,13 @@ public:
|
|||
|
||||
//==============================================================================
|
||||
/** Changes the width used to draw the white keys. */
|
||||
void setKeyWidth (const float widthInPixels);
|
||||
void setKeyWidth (float widthInPixels);
|
||||
|
||||
/** Returns the width that was set by setKeyWidth(). */
|
||||
float getKeyWidth() const throw() { return keyWidth; }
|
||||
|
||||
/** Changes the keyboard's current direction. */
|
||||
void setOrientation (const Orientation newOrientation);
|
||||
void setOrientation (Orientation newOrientation);
|
||||
|
||||
/** Returns the keyboard's current direction. */
|
||||
const Orientation getOrientation() const throw() { return orientation; }
|
||||
|
|
@ -150,8 +150,8 @@ public:
|
|||
|
||||
Note that the values here are inclusive and must be between 0 and 127.
|
||||
*/
|
||||
void setAvailableRange (const int lowestNote,
|
||||
const int highestNote);
|
||||
void setAvailableRange (int lowestNote,
|
||||
int highestNote);
|
||||
|
||||
/** Returns the first note in the available range.
|
||||
|
||||
|
|
@ -188,7 +188,7 @@ public:
|
|||
/** If set to true, then scroll buttons will appear at either end of the keyboard
|
||||
if there are too many notes to fit them all in the component at once.
|
||||
*/
|
||||
void setScrollButtonsVisible (const bool canScroll);
|
||||
void setScrollButtonsVisible (bool canScroll);
|
||||
|
||||
//==============================================================================
|
||||
/** A set of colour IDs to use to change the colour of various aspects of the keyboard.
|
||||
|
|
@ -233,13 +233,13 @@ public:
|
|||
the base octave, see setKeyPressBaseOctave()
|
||||
*/
|
||||
void setKeyPressForNote (const KeyPress& key,
|
||||
const int midiNoteOffsetFromC);
|
||||
int midiNoteOffsetFromC);
|
||||
|
||||
/** Removes any key-mappings for a given note.
|
||||
|
||||
For a description of what the note number means, see setKeyPressForNote().
|
||||
*/
|
||||
void removeKeyPressForNote (const int midiNoteOffsetFromC);
|
||||
void removeKeyPressForNote (int midiNoteOffsetFromC);
|
||||
|
||||
/** Changes the base note above which key-press-triggered notes are played.
|
||||
|
||||
|
|
@ -250,7 +250,7 @@ public:
|
|||
indicates which C is the base note to which the key-mapped notes are
|
||||
relative.
|
||||
*/
|
||||
void setKeyPressBaseOctave (const int newOctaveNumber);
|
||||
void setKeyPressBaseOctave (int newOctaveNumber);
|
||||
|
||||
/** This sets the octave number which is shown as the octave number for middle C.
|
||||
|
||||
|
|
@ -263,7 +263,7 @@ public:
|
|||
|
||||
@see getOctaveForMiddleC
|
||||
*/
|
||||
void setOctaveForMiddleC (const int octaveNumForMiddleC) throw();
|
||||
void setOctaveForMiddleC (int octaveNumForMiddleC) throw();
|
||||
|
||||
/** This returns the value set by setOctaveForMiddleC().
|
||||
@see setOctaveForMiddleC
|
||||
|
|
|
|||
|
|
@ -96,7 +96,7 @@ public:
|
|||
*/
|
||||
void addSettingsPage (const String& pageTitle,
|
||||
const char* imageData,
|
||||
const int imageDataSize);
|
||||
int imageDataSize);
|
||||
|
||||
/** Utility method to display this panel in a DialogWindow.
|
||||
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ public:
|
|||
@returns true if the movie opens successfully
|
||||
*/
|
||||
bool loadMovie (const File& movieFile,
|
||||
const bool isControllerVisible);
|
||||
bool isControllerVisible);
|
||||
|
||||
/** Tries to load a QuickTime movie from a URL into the player.
|
||||
|
||||
|
|
@ -93,7 +93,7 @@ public:
|
|||
@returns true if the movie opens successfully
|
||||
*/
|
||||
bool loadMovie (const URL& movieURL,
|
||||
const bool isControllerVisible);
|
||||
bool isControllerVisible);
|
||||
|
||||
/** Tries to load a QuickTime movie from a stream into the player.
|
||||
|
||||
|
|
@ -109,7 +109,7 @@ public:
|
|||
@returns true if the movie opens successfully
|
||||
*/
|
||||
bool loadMovie (InputStream* movieStream,
|
||||
const bool isControllerVisible);
|
||||
bool isControllerVisible);
|
||||
|
||||
/** Closes the movie, if one is open. */
|
||||
void closeMovie();
|
||||
|
|
@ -158,7 +158,7 @@ public:
|
|||
void goToStart();
|
||||
|
||||
/** Sets the movie's position to a given time. */
|
||||
void setPosition (const double seconds);
|
||||
void setPosition (double seconds);
|
||||
|
||||
/** Returns the current play position of the movie. */
|
||||
double getPosition() const;
|
||||
|
|
@ -168,13 +168,13 @@ public:
|
|||
A value of 1 is normal speed, greater values play it proportionately faster,
|
||||
smaller values play it slower.
|
||||
*/
|
||||
void setSpeed (const float newSpeed);
|
||||
void setSpeed (float newSpeed);
|
||||
|
||||
/** Changes the movie's playback volume.
|
||||
|
||||
@param newVolume the volume in the range 0 (silent) to 1.0 (full)
|
||||
*/
|
||||
void setMovieVolume (const float newVolume);
|
||||
void setMovieVolume (float newVolume);
|
||||
|
||||
/** Returns the movie's playback volume.
|
||||
|
||||
|
|
@ -183,7 +183,7 @@ public:
|
|||
float getMovieVolume() const;
|
||||
|
||||
/** Tells the movie whether it should loop. */
|
||||
void setLooping (const bool shouldLoop);
|
||||
void setLooping (bool shouldLoop);
|
||||
|
||||
/** Returns true if the movie is currently looping.
|
||||
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ public:
|
|||
the browser using resources in the background when it's not
|
||||
actually being used.
|
||||
*/
|
||||
WebBrowserComponent (const bool unloadPageWhenBrowserIsHidden = true);
|
||||
WebBrowserComponent (bool unloadPageWhenBrowserIsHidden = true);
|
||||
|
||||
/** Destructor. */
|
||||
~WebBrowserComponent();
|
||||
|
|
|
|||
|
|
@ -365,7 +365,7 @@ private:
|
|||
Font font;
|
||||
Component* associatedComponent;
|
||||
|
||||
void updateLayout (const bool onlyIncreaseSize);
|
||||
void updateLayout (bool onlyIncreaseSize);
|
||||
|
||||
// disable copy constructor
|
||||
AlertWindow (const AlertWindow&);
|
||||
|
|
|
|||
|
|
@ -66,8 +66,8 @@ public:
|
|||
*/
|
||||
DialogWindow (const String& name,
|
||||
const Colour& backgroundColour,
|
||||
const bool escapeKeyTriggersCloseButton,
|
||||
const bool addToDesktop = true);
|
||||
bool escapeKeyTriggersCloseButton,
|
||||
bool addToDesktop = true);
|
||||
|
||||
/** Destructor.
|
||||
|
||||
|
|
@ -116,9 +116,9 @@ public:
|
|||
Component* contentComponent,
|
||||
Component* componentToCentreAround,
|
||||
const Colour& backgroundColour,
|
||||
const bool escapeKeyTriggersCloseButton,
|
||||
const bool shouldBeResizable = false,
|
||||
const bool useBottomRightCornerResizer = false);
|
||||
bool escapeKeyTriggersCloseButton,
|
||||
bool shouldBeResizable = false,
|
||||
bool useBottomRightCornerResizer = false);
|
||||
|
||||
//==============================================================================
|
||||
juce_UseDebuggingNewOperator
|
||||
|
|
|
|||
|
|
@ -91,8 +91,8 @@ public:
|
|||
*/
|
||||
DocumentWindow (const String& name,
|
||||
const Colour& backgroundColour,
|
||||
const int requiredButtons,
|
||||
const bool addToDesktop = true);
|
||||
int requiredButtons,
|
||||
bool addToDesktop = true);
|
||||
|
||||
/** Destructor.
|
||||
|
||||
|
|
@ -118,7 +118,7 @@ public:
|
|||
void setIcon (const Image* imageToUse);
|
||||
|
||||
/** Changes the height of the title-bar. */
|
||||
void setTitleBarHeight (const int newHeight);
|
||||
void setTitleBarHeight (int newHeight);
|
||||
|
||||
/** Returns the current title bar height. */
|
||||
int getTitleBarHeight() const;
|
||||
|
|
@ -132,15 +132,15 @@ public:
|
|||
@param positionTitleBarButtonsOnLeft if true, the buttons should go at the
|
||||
left side of the bar; if false, they'll be placed at the right
|
||||
*/
|
||||
void setTitleBarButtonsRequired (const int requiredButtons,
|
||||
const bool positionTitleBarButtonsOnLeft);
|
||||
void setTitleBarButtonsRequired (int requiredButtons,
|
||||
bool positionTitleBarButtonsOnLeft);
|
||||
|
||||
/** Sets whether the title should be centred within the window.
|
||||
|
||||
If true, the title text is shown in the middle of the title-bar; if false,
|
||||
it'll be shown at the left of the bar.
|
||||
*/
|
||||
void setTitleBarTextCentred (const bool textShouldBeCentred);
|
||||
void setTitleBarTextCentred (bool textShouldBeCentred);
|
||||
|
||||
/** Creates a menu inside this window.
|
||||
|
||||
|
|
@ -154,7 +154,7 @@ public:
|
|||
or less to use the look-and-feel's default size.
|
||||
*/
|
||||
void setMenuBar (MenuBarModel* menuBarModel,
|
||||
const int menuBarHeight = 0);
|
||||
int menuBarHeight = 0);
|
||||
|
||||
//==============================================================================
|
||||
/** This method is called when the user tries to close the window.
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ public:
|
|||
desktop; if false, you can use it as a child component
|
||||
*/
|
||||
ResizableWindow (const String& name,
|
||||
const bool addToDesktop);
|
||||
bool addToDesktop);
|
||||
|
||||
/** Creates a ResizableWindow.
|
||||
|
||||
|
|
@ -77,7 +77,7 @@ public:
|
|||
*/
|
||||
ResizableWindow (const String& name,
|
||||
const Colour& backgroundColour,
|
||||
const bool addToDesktop);
|
||||
bool addToDesktop);
|
||||
|
||||
/** Destructor.
|
||||
|
||||
|
|
@ -124,8 +124,8 @@ public:
|
|||
around the edge
|
||||
@see setResizeLimits, isResizable
|
||||
*/
|
||||
void setResizable (const bool shouldBeResizable,
|
||||
const bool useBottomRightCornerResizer);
|
||||
void setResizable (bool shouldBeResizable,
|
||||
bool useBottomRightCornerResizer);
|
||||
|
||||
/** True if resizing is enabled.
|
||||
|
||||
|
|
@ -143,10 +143,10 @@ public:
|
|||
|
||||
@see setResizable, setFixedAspectRatio
|
||||
*/
|
||||
void setResizeLimits (const int newMinimumWidth,
|
||||
const int newMinimumHeight,
|
||||
const int newMaximumWidth,
|
||||
const int newMaximumHeight) throw();
|
||||
void setResizeLimits (int newMinimumWidth,
|
||||
int newMinimumHeight,
|
||||
int newMaximumWidth,
|
||||
int newMaximumHeight) throw();
|
||||
|
||||
/** Returns the bounds constrainer object that this window is using.
|
||||
|
||||
|
|
@ -185,7 +185,7 @@ public:
|
|||
|
||||
@see isFullScreen
|
||||
*/
|
||||
void setFullScreen (const bool shouldBeFullScreen);
|
||||
void setFullScreen (bool shouldBeFullScreen);
|
||||
|
||||
/** Returns true if the window is currently minimised.
|
||||
|
||||
|
|
@ -200,7 +200,7 @@ public:
|
|||
|
||||
@see isMinimised
|
||||
*/
|
||||
void setMinimised (const bool shouldMinimise);
|
||||
void setMinimised (bool shouldMinimise);
|
||||
|
||||
//==============================================================================
|
||||
/** Returns a string which encodes the window's current size and position.
|
||||
|
|
@ -257,9 +257,9 @@ public:
|
|||
it always fits around the size of the content component. If false, the
|
||||
new content will be resized to fit the current space available.
|
||||
*/
|
||||
void setContentComponent (Component* const newContentComponent,
|
||||
const bool deleteOldOne = true,
|
||||
const bool resizeToFit = false);
|
||||
void setContentComponent (Component* newContentComponent,
|
||||
bool deleteOldOne = true,
|
||||
bool resizeToFit = false);
|
||||
|
||||
/** Changes the window so that the content component ends up with the specified size.
|
||||
|
||||
|
|
@ -327,14 +327,14 @@ protected:
|
|||
If you know what you're doing and are sure you really want to add a component, specify
|
||||
a base-class method call to Component::addAndMakeVisible(), to side-step this warning.
|
||||
*/
|
||||
void addChildComponent (Component* const child, int zOrder = -1);
|
||||
void addChildComponent (Component* child, int zOrder = -1);
|
||||
/** Overridden to warn people about adding components directly to this component
|
||||
instead of using setContentComponent().
|
||||
|
||||
If you know what you're doing and are sure you really want to add a component, specify
|
||||
a base-class method call to Component::addAndMakeVisible(), to side-step this warning.
|
||||
*/
|
||||
void addAndMakeVisible (Component* const child, int zOrder = -1);
|
||||
void addAndMakeVisible (Component* child, int zOrder = -1);
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -97,10 +97,10 @@ public:
|
|||
the mouse (anywhere)
|
||||
*/
|
||||
void show (const String& title,
|
||||
Image* const backgroundImage,
|
||||
const int minimumTimeToDisplayFor,
|
||||
const bool useDropShadow,
|
||||
const bool removeOnMouseClick = true);
|
||||
Image* backgroundImage,
|
||||
int minimumTimeToDisplayFor,
|
||||
bool useDropShadow,
|
||||
bool removeOnMouseClick = true);
|
||||
|
||||
/** Creates a SplashScreen object with a specified size.
|
||||
|
||||
|
|
@ -125,11 +125,11 @@ public:
|
|||
the mouse (anywhere)
|
||||
*/
|
||||
void show (const String& title,
|
||||
const int width,
|
||||
const int height,
|
||||
const int minimumTimeToDisplayFor,
|
||||
const bool useDropShadow,
|
||||
const bool removeOnMouseClick = true);
|
||||
int width,
|
||||
int height,
|
||||
int minimumTimeToDisplayFor,
|
||||
bool useDropShadow,
|
||||
bool removeOnMouseClick = true);
|
||||
|
||||
//==============================================================================
|
||||
/** @internal */
|
||||
|
|
|
|||
|
|
@ -109,9 +109,9 @@ public:
|
|||
(if it has one)
|
||||
*/
|
||||
ThreadWithProgressWindow (const String& windowTitle,
|
||||
const bool hasProgressBar,
|
||||
const bool hasCancelButton,
|
||||
const int timeOutMsWhenCancelling = 10000,
|
||||
bool hasProgressBar,
|
||||
bool hasCancelButton,
|
||||
int timeOutMsWhenCancelling = 10000,
|
||||
const String& cancelButtonText = JUCE_T("Cancel"));
|
||||
|
||||
/** Destructor. */
|
||||
|
|
@ -129,14 +129,14 @@ public:
|
|||
Thread::startThread() for values
|
||||
@returns true if the thread finished normally; false if the user pressed cancel
|
||||
*/
|
||||
bool runThread (const int threadPriority = 5);
|
||||
bool runThread (int threadPriority = 5);
|
||||
|
||||
/** The thread should call this periodically to update the position of the progress bar.
|
||||
|
||||
@param newProgress the progress, from 0.0 to 1.0
|
||||
@see setStatusMessage
|
||||
*/
|
||||
void setProgress (const double newProgress);
|
||||
void setProgress (double newProgress);
|
||||
|
||||
/** The thread can call this to change the message that's displayed in the dialog box.
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ public:
|
|||
@see TooltipClient, LookAndFeel::drawTooltip, LookAndFeel::getTooltipSize
|
||||
*/
|
||||
TooltipWindow (Component* parentComponent = 0,
|
||||
const int millisecondsBeforeTipAppears = 700);
|
||||
int millisecondsBeforeTipAppears = 700);
|
||||
|
||||
/** Destructor. */
|
||||
~TooltipWindow();
|
||||
|
|
@ -77,7 +77,7 @@ public:
|
|||
/** Changes the time before the tip appears.
|
||||
This lets you change the value that was set in the constructor.
|
||||
*/
|
||||
void setMillisecondsBeforeTipAppears (const int newTimeMs = 700) throw();
|
||||
void setMillisecondsBeforeTipAppears (int newTimeMs = 700) throw();
|
||||
|
||||
//==============================================================================
|
||||
/** A set of colour IDs to use to change the colour of various aspects of the tooltip.
|
||||
|
|
@ -111,7 +111,7 @@ private:
|
|||
void mouseEnter (const MouseEvent& e);
|
||||
void timerCallback();
|
||||
|
||||
static const String getTipFor (Component* const c);
|
||||
static const String getTipFor (Component* c);
|
||||
void showFor (const String& tip);
|
||||
void hide();
|
||||
|
||||
|
|
|
|||
|
|
@ -62,8 +62,7 @@ public:
|
|||
@param addToDesktop if true, the window will be automatically added to the
|
||||
desktop; if false, you can use it as a child component
|
||||
*/
|
||||
TopLevelWindow (const String& name,
|
||||
const bool addToDesktop);
|
||||
TopLevelWindow (const String& name, bool addToDesktop);
|
||||
|
||||
/** Destructor. */
|
||||
~TopLevelWindow();
|
||||
|
|
@ -92,17 +91,17 @@ public:
|
|||
screen.
|
||||
*/
|
||||
void centreAroundComponent (Component* componentToCentreAround,
|
||||
const int width, const int height);
|
||||
int width, int height);
|
||||
|
||||
//==============================================================================
|
||||
/** Turns the drop-shadow on and off. */
|
||||
void setDropShadowEnabled (const bool useShadow);
|
||||
void setDropShadowEnabled (bool useShadow);
|
||||
|
||||
/** Sets whether an OS-native title bar will be used, or a Juce one.
|
||||
|
||||
@see isUsingNativeTitleBar
|
||||
*/
|
||||
void setUsingNativeTitleBar (const bool useNativeTitleBar);
|
||||
void setUsingNativeTitleBar (bool useNativeTitleBar);
|
||||
|
||||
/** Returns true if the window is currently using an OS-native title bar.
|
||||
|
||||
|
|
@ -121,7 +120,7 @@ public:
|
|||
|
||||
The index is 0 to (getNumTopLevelWindows() - 1).
|
||||
*/
|
||||
static TopLevelWindow* getTopLevelWindow (const int index) throw();
|
||||
static TopLevelWindow* getTopLevelWindow (int index) throw();
|
||||
|
||||
/** Returns the currently-active top level window.
|
||||
|
||||
|
|
@ -162,7 +161,7 @@ private:
|
|||
bool useDropShadow, useNativeTitleBar, windowIsActive_;
|
||||
ScopedPointer <DropShadower> shadower;
|
||||
|
||||
void setWindowActive (const bool isNowActive) throw();
|
||||
void setWindowActive (bool isNowActive) throw();
|
||||
|
||||
TopLevelWindow (const TopLevelWindow&);
|
||||
TopLevelWindow& operator= (const TopLevelWindow&);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue