namespace blink {
class CompositeEditCommand;
-class DataTransfer;
-class EditCommand;
class EditCommandComposition;
class EditorClient;
class EditorInternalCommand;
class LocalFrame;
-class HTMLElement;
class HitTestResult;
class KillRing;
class Pasteboard;
-class SharedBuffer;
-class SimpleFontData;
class SpellChecker;
class StylePropertySet;
-class Text;
class TextEvent;
class UndoStack;
EditorClient& client() const;
- LocalFrame& frame() const { return m_frame; }
-
CompositeEditCommand* lastEditCommand() { return m_lastEditCommand.get(); }
void handleKeyboardEvent(KeyboardEvent*);
bool shouldStyleWithCSS() const { return m_shouldStyleWithCSS; }
class Command {
+ STACK_ALLOCATED();
public:
Command();
- Command(const EditorInternalCommand*, EditorCommandSource, PassRefPtr<LocalFrame>);
+ Command(const EditorInternalCommand*, EditorCommandSource, PassRefPtrWillBeRawPtr<LocalFrame>);
bool execute(const String& parameter = String(), Event* triggeringEvent = 0) const;
bool execute(Event* triggeringEvent) const;
// Returns 0 if this Command is not supported.
int idForHistogram() const;
private:
+ LocalFrame& frame() const
+ {
+ ASSERT(m_frame);
+ return *m_frame;
+ }
+
const EditorInternalCommand* m_command;
EditorCommandSource m_source;
- RefPtr<LocalFrame> m_frame;
+ RefPtrWillBeMember<LocalFrame> m_frame;
};
Command command(const String& commandName); // Command source is CommandFromMenuOrKeyBinding.
Command command(const String& commandName, EditorCommandSource);
void trace(Visitor*);
private:
- LocalFrame& m_frame;
+ RawPtrWillBeMember<LocalFrame> m_frame;
RefPtrWillBeMember<CompositeEditCommand> m_lastEditCommand;
int m_preventRevealSelection;
bool m_shouldStartNewKillRingSequence;
explicit Editor(LocalFrame&);
+ LocalFrame& frame() const
+ {
+ ASSERT(m_frame);
+ return *m_frame;
+ }
+
bool canDeleteRange(Range*) const;
UndoStack* undoStack() const;