2 Copyright (C) 2000-2004 SKYRIX Software AG
4 This file is part of OpenGroupware.org.
6 OGo is free software; you can redistribute it and/or modify it under
7 the terms of the GNU Lesser General Public License as published by the
8 Free Software Foundation; either version 2, or (at your option) any
11 OGo is distributed in the hope that it will be useful, but WITHOUT ANY
12 WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
14 License for more details.
16 You should have received a copy of the GNU Lesser General Public
17 License along with OGo; see the file COPYING. If not, write to the
18 Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
23 #ifndef __WEExtensions_WEClientCapabilities_H__
24 #define __WEExtensions_WEClientCapabilities_H__
26 #import <Foundation/NSObject.h>
30 @interface WEClientCapabilities : NSObject
34 unsigned short browser;
37 unsigned char browserMajorVersion;
38 unsigned char browserMinorVersion;
48 - (NSString *)userAgent;
49 - (NSString *)userAgentType;
52 - (unsigned char)majorVersion;
53 - (unsigned char)minorVersion;
55 /* browser capabilities */
57 - (BOOL)isJavaScriptBrowser;
58 - (BOOL)isVBScriptBrowser;
59 - (BOOL)isFastTableBrowser;
60 - (BOOL)isCSS1Browser;
61 - (BOOL)isCSS2Browser;
62 - (BOOL)ignoresCSSOnFormElements;
63 - (BOOL)isTextModeBrowser;
64 - (BOOL)isIFrameBrowser;
68 - (BOOL)isXmlRpcClient;
71 - (BOOL)doesSupportCSSOverflow;
72 - (BOOL)doesSupportDHTMLDragAndDrop;
73 - (BOOL)doesSupportXMLDataIslands;
74 - (BOOL)doesSupportUTF8Encoding;
76 /* user-agent (it's better to use ^capabilities !) */
78 - (BOOL)isInternetExplorer;
79 - (BOOL)isInternetExplorer5;
95 - (BOOL)isWindowsBrowser;
96 - (BOOL)isLinuxBrowser;
98 - (BOOL)isSunOSBrowser;
99 - (BOOL)isUnixBrowser;
100 - (BOOL)isX11Browser;
104 #include <NGObjWeb/WORequest.h>
106 @interface WORequest(ClientCapabilities)
108 /* the object is cached in the WORequest's userInfo */
109 - (WEClientCapabilities *)clientCapabilities;
113 #include <NGObjWeb/WODynamicElement.h>
116 The following element uses JavaScript to find out even more about the client
120 @interface JSClientCapabilityDetector : WODynamicElement
122 WOAssociation *formName;
123 WOAssociation *clientCaps;
127 #endif /* __WEExtensions_WEClientCapabilities_H__ */