mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Got rid of some very old legacy VC6 workaround typedefs
This commit is contained in:
parent
90f3d11ab8
commit
a7e3339f86
15 changed files with 12 additions and 55 deletions
|
|
@ -206,7 +206,7 @@ bool Value::operator!= (const Value& other) const
|
|||
}
|
||||
|
||||
//==============================================================================
|
||||
void Value::addListener (ValueListener* const listener)
|
||||
void Value::addListener (Value::Listener* listener)
|
||||
{
|
||||
if (listener != nullptr)
|
||||
{
|
||||
|
|
@ -217,7 +217,7 @@ void Value::addListener (ValueListener* const listener)
|
|||
}
|
||||
}
|
||||
|
||||
void Value::removeListener (ValueListener* const listener)
|
||||
void Value::removeListener (Value::Listener* listener)
|
||||
{
|
||||
listeners.remove (listener);
|
||||
|
||||
|
|
@ -230,7 +230,7 @@ void Value::callListeners()
|
|||
if (listeners.size() > 0)
|
||||
{
|
||||
Value v (*this); // (create a copy in case this gets deleted by a callback)
|
||||
listeners.call ([&] (ValueListener& l) { l.valueChanged (v); });
|
||||
listeners.call ([&] (Value::Listener& l) { l.valueChanged (v); });
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -237,7 +237,5 @@ private:
|
|||
/** Writes a Value to an OutputStream as a UTF8 string. */
|
||||
OutputStream& JUCE_CALLTYPE operator<< (OutputStream&, const Value&);
|
||||
|
||||
/** This typedef is just for compatibility with old code - newer code should use the Value::Listener class directly. */
|
||||
typedef Value::Listener ValueListener;
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
|
|
@ -514,9 +514,5 @@ private:
|
|||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Button)
|
||||
};
|
||||
|
||||
#ifndef DOXYGEN
|
||||
/** This typedef is just for compatibility with old code and VC6 - newer code should use Button::Listener instead. */
|
||||
typedef Button::Listener ButtonListener;
|
||||
#endif
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
|
|
@ -427,7 +427,5 @@ private:
|
|||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (ScrollBar)
|
||||
};
|
||||
|
||||
/** This typedef is just for compatibility with old code - newer code should use the ScrollBar::Listener class directly. */
|
||||
typedef ScrollBar::Listener ScrollBarListener;
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
|
|
@ -187,7 +187,5 @@ private:
|
|||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MenuBarModel)
|
||||
};
|
||||
|
||||
/** This typedef is just for compatibility with old code - newer code should use the MenuBarModel::Listener class directly. */
|
||||
typedef MenuBarModel::Listener MenuBarModelListener;
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ class TextPropertyComponent::LabelComp : public Label,
|
|||
{
|
||||
public:
|
||||
LabelComp (TextPropertyComponent& tpc, int charLimit, bool multiline, bool editable)
|
||||
: Label (String(), String()),
|
||||
: Label ({}, {}),
|
||||
owner (tpc),
|
||||
maxChars (charLimit),
|
||||
isMultiline (multiline)
|
||||
|
|
@ -159,15 +159,8 @@ void TextPropertyComponent::textWasEdited()
|
|||
callListeners();
|
||||
}
|
||||
|
||||
void TextPropertyComponent::addListener (TextPropertyComponentListener* const listener)
|
||||
{
|
||||
listenerList.add (listener);
|
||||
}
|
||||
|
||||
void TextPropertyComponent::removeListener (TextPropertyComponentListener* const listener)
|
||||
{
|
||||
listenerList.remove (listener);
|
||||
}
|
||||
void TextPropertyComponent::addListener (TextPropertyComponent::Listener* l) { listenerList.add (l); }
|
||||
void TextPropertyComponent::removeListener (TextPropertyComponent::Listener* l) { listenerList.remove (l); }
|
||||
|
||||
void TextPropertyComponent::callListeners()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -156,9 +156,5 @@ private:
|
|||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (TextPropertyComponent)
|
||||
};
|
||||
|
||||
#ifndef DOXYGEN
|
||||
/** This typedef is just for compatibility with old code and VC6 - newer code should use TextPropertyComponent::Listener instead. */
|
||||
typedef TextPropertyComponent::Listener TextPropertyComponentListener;
|
||||
#endif
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
|
|
@ -623,8 +623,8 @@ void ComboBox::setScrollWheelEnabled (bool enabled) noexcept
|
|||
}
|
||||
|
||||
//==============================================================================
|
||||
void ComboBox::addListener (ComboBoxListener* listener) { listeners.add (listener); }
|
||||
void ComboBox::removeListener (ComboBoxListener* listener) { listeners.remove (listener); }
|
||||
void ComboBox::addListener (ComboBox::Listener* l) { listeners.add (l); }
|
||||
void ComboBox::removeListener (ComboBox::Listener* l) { listeners.remove (l); }
|
||||
|
||||
void ComboBox::handleAsyncUpdate()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -447,7 +447,5 @@ private:
|
|||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (ComboBox)
|
||||
};
|
||||
|
||||
/** This typedef is just for compatibility with old code - newer code should use the ComboBox::Listener class directly. */
|
||||
typedef ComboBox::Listener ComboBoxListener;
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
|
|
@ -190,7 +190,7 @@ void Label::textWasChanged() {}
|
|||
void Label::editorShown (TextEditor* textEditor)
|
||||
{
|
||||
Component::BailOutChecker checker (this);
|
||||
listeners.callChecked (checker, [this, textEditor] (LabelListener& l) { l.editorShown (this, *textEditor); });
|
||||
listeners.callChecked (checker, [this, textEditor] (Label::Listener& l) { l.editorShown (this, *textEditor); });
|
||||
}
|
||||
|
||||
void Label::editorAboutToBeHidden (TextEditor* textEditor)
|
||||
|
|
@ -199,7 +199,7 @@ void Label::editorAboutToBeHidden (TextEditor* textEditor)
|
|||
peer->dismissPendingTextInput();
|
||||
|
||||
Component::BailOutChecker checker (this);
|
||||
listeners.callChecked (checker, [this, textEditor] (LabelListener& l) { l.editorHidden (this, *textEditor); });
|
||||
listeners.callChecked (checker, [this, textEditor] (Label::Listener& l) { l.editorHidden (this, *textEditor); });
|
||||
}
|
||||
|
||||
void Label::showEditor()
|
||||
|
|
@ -395,15 +395,8 @@ KeyboardFocusTraverser* Label::createFocusTraverser()
|
|||
}
|
||||
|
||||
//==============================================================================
|
||||
void Label::addListener (LabelListener* listener)
|
||||
{
|
||||
listeners.add (listener);
|
||||
}
|
||||
|
||||
void Label::removeListener (LabelListener* listener)
|
||||
{
|
||||
listeners.remove (listener);
|
||||
}
|
||||
void Label::addListener (Label::Listener* l) { listeners.add (l); }
|
||||
void Label::removeListener (Label::Listener* l) { listeners.remove (l); }
|
||||
|
||||
void Label::callChangeListeners()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -349,7 +349,5 @@ private:
|
|||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Label)
|
||||
};
|
||||
|
||||
/** This typedef is just for compatibility with old code - newer code should use the Label::Listener class directly. */
|
||||
typedef Label::Listener LabelListener;
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
|
|
@ -960,7 +960,5 @@ private:
|
|||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Slider)
|
||||
};
|
||||
|
||||
/** This typedef is just for compatibility with old code - newer code should use the Slider::Listener class directly. */
|
||||
typedef Slider::Listener SliderListener;
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
|
|
@ -453,7 +453,5 @@ private:
|
|||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (TableHeaderComponent)
|
||||
};
|
||||
|
||||
/** This typedef is just for compatibility with old code - newer code should use the TableHeaderComponent::Listener class directly. */
|
||||
typedef TableHeaderComponent::Listener TableHeaderListener;
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
|
|
@ -770,7 +770,5 @@ private:
|
|||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (TextEditor)
|
||||
};
|
||||
|
||||
/** This typedef is just for compatibility with old code - newer code should use the TextEditor::Listener class directly. */
|
||||
typedef TextEditor::Listener TextEditorListener;
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
|
|
@ -159,11 +159,6 @@ private:
|
|||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (CameraDevice)
|
||||
};
|
||||
|
||||
#ifndef DOXYGEN
|
||||
/** This typedef is just for compatibility with VC6 - newer code should use the CameraDevice::Listener class directly. */
|
||||
typedef CameraDevice::Listener CameraImageListener;
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
} // namespace juce
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue