00001 /* 00002 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved. 00003 * Copyright (C) 2007 Pleyo. All rights reserved. 00004 * 00005 * Redistribution and use in source and binary forms, with or without 00006 * modification, are permitted provided that the following conditions 00007 * are met: 00008 * 1. Redistributions of source code must retain the above copyright 00009 * notice, this list of conditions and the following disclaimer. 00010 * 2. Redistributions in binary form must reproduce the above copyright 00011 * notice, this list of conditions and the following disclaimer in the 00012 * documentation and/or other materials provided with the distribution. 00013 * 00014 * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY 00015 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 00016 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 00017 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR 00018 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 00019 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 00020 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 00021 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY 00022 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 00023 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 00024 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 00025 */ 00026 00027 #ifndef WidgetClient_h 00028 #define WidgetClient_h 00029 00030 namespace WebCore { 00031 00032 class Element; 00033 00034 } 00035 using WebCore::Element; 00036 00037 namespace BAL { 00038 00039 class Widget; 00040 00041 class WidgetClient { 00042 public: 00046 virtual ~WidgetClient() { } 00047 00051 virtual void scrollToVisible(Widget*) { } 00052 00056 virtual void focusIn(Widget*) { } 00060 virtual void focusOut(Widget*) { } 00061 00065 virtual void clicked(Widget*) { } 00069 virtual void valueChanged(Widget*) { } 00073 virtual void selectionChanged(Widget*) { } 00074 00075 virtual void returnPressed(Widget*) { } 00076 virtual void performSearch(Widget*) { } 00077 00081 virtual Element* element(Widget*) { return 0; } 00085 virtual void sendConsumedMouseUp(Widget*) { } 00089 virtual bool isVisible(Widget*) { return false; } 00090 }; 00091 00092 } 00093 00094 using BAL::WidgetClient; 00095 00096 #endif // WidgetClient_h