Changeset 24955 in webkit
- Timestamp:
- Aug 9, 2007 8:28:07 AM (17 years ago)
- Location:
- S60/branches/3.1m
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
S60/branches/3.1m/S60WebUi/ChangeLog
r16036 r24955 1 09-08-2007 Mahesh Kulkarni <mahesh.kulkarni@Nokia.com> 2 Reviewed by Sachin Padma 3 4 DESC: [S60] Problem with CPluginSkin::PluginScriptableObject 5 http://bugs.webkit.org/show_bug.cgi?id=14383 6 7 * WebUi/inc/WebUiCRKeys.h: Added CRKey KPluginScriptabilityAllowed 8 9 1 10 2006-08-25 w3liu <wei.liu@nokia.com> 2 11 -
S60/branches/3.1m/S60WebUi/WebUi/inc/WebUiCRKeys.h
r14549 r24955 10 10 * All rights reserved. 11 11 * 12 * 13 * 14 * 12 * Redistribution and use in source and binary forms, with or without 13 * modification, are permitted provided that the following conditions 14 * are met: 15 15 * 16 16 * * Redistributions of source code must retain the above copyright … … 24 24 * from this software without specific prior written permission. 25 25 * 26 * 27 * 28 * 29 * 30 * 31 * 32 * 33 * 34 * 35 * 36 * 37 * 26 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 27 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 28 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 29 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 30 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 31 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 32 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 33 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 34 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 35 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE 36 * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH 37 * DAMAGE. 38 38 * 39 39 * Please see file patentlicense.txt for further grants. … … 59 59 // Images enabled. 60 60 // Valid values: 0 = off 1 = on 61 const TUint32 KBrowserNGImagesEnabled = 61 const TUint32 KBrowserNGImagesEnabled = 0x00000001; 62 62 63 63 // Browser font size. 64 64 // Valid values:any positive 32-bit integer value 65 const TUint32 KBrowserNGFontSize = 65 const TUint32 KBrowserNGFontSize = 0x00000002; 66 66 67 67 // Browser encoding setting. 68 68 // Valid values: any positive 32-bit integer value 69 69 // 0 = automatic 70 const TUint32 KBrowserNGEncoding = 70 const TUint32 KBrowserNGEncoding = 0x00000003; 71 71 72 72 // Browser uses cookies. 73 73 // Valid values: 0 = reject 1 = allow 74 const TUint32 KBrowserNGCookiesEnabled = 74 const TUint32 KBrowserNGCookiesEnabled = 0x00000004; 75 75 76 76 // Boolean value which determines whether ECMA Script 77 77 // setting is enabled or disabled in Browser. 78 78 // Valid values: 0 = disabled 1 = enabled 79 const TUint32 KBrowserNGECMAScriptSupport = 79 const TUint32 KBrowserNGECMAScriptSupport = 0x00000005; 80 80 81 81 // Show HTTP security warnings. 82 82 // Valid values: 0 = off 1 = on 83 const TUint32 KBrowserNGShowSecurityWarnings= 83 const TUint32 KBrowserNGShowSecurityWarnings= 0x00000006; 84 84 85 85 // Show Page Overview. 86 86 // Valid values: 0 = off 1 = on 87 const TUint32 KBrowserNGPageOverview = 87 const TUint32 KBrowserNGPageOverview = 0x00000007; 88 88 89 89 // Mime types for HTTP accept header. 90 90 // Any String value 91 const TUint32 KBrowserNGMimeTypes = 91 const TUint32 KBrowserNGMimeTypes = 0x00000008; 92 92 93 93 // Show History view on back softkey press. 94 94 // Valid values: 0 = off 1 = on 95 const TUint32 KBrowserNGBackList = 95 const TUint32 KBrowserNGBackList = 0x00000009; 96 96 97 97 // Auto refresh. 98 98 // Valid values: 0 = off 1 = on 99 const TUint32 KBrowserNGAutoRefresh = 99 const TUint32 KBrowserNGAutoRefresh = 0x0000000A; 100 100 101 101 // BrowserNG engine cache size in KBytes 102 102 // Valid values: any positive 32-bit integer value 103 const TUint32 KBrowserNGMemoryCacheSize = 103 const TUint32 KBrowserNGMemoryCacheSize = 0x0000000B; 104 104 105 105 // The setting for encoding a URL with UTF-8 or the original encoding. 106 106 // Valid values: 0 = off 1 = on 107 const TUint32 KBrowserNGUtf8Encoding = 107 const TUint32 KBrowserNGUtf8Encoding = 0x0000000C; 108 108 109 109 // Browser Adaptive Bookmarks mode setting. … … 144 144 // The flag that's set if Browser build is to be used in United States (USA) 145 145 // Valid values: 0 = not set (non-US build) 1 = set (US build) 146 const TUint32 KBrowserUsBuild = 0x00000014; 146 const TUint32 KBrowserUsBuild = 0x00000014; 147 148 // This Interger type will have UID's of plugins that can access scriptability 149 // Valid values: TUid's 150 const TUint32 KPluginScriptabilityAllowed = 0x00000015; 147 151 148 152 #endif // WEBUICRKEYS_H -
S60/branches/3.1m/WebKit/ChangeLog
r24941 r24955 1 2007-08-09 Mahesh Kulkarni <mahesh.kulkarni@nokia.com> 2 Reviewed by Sachin. 3 DESC: [S60] Problem with CPluginSkin::PluginScriptableObject 4 http://bugs.webkit.org/show_bug.cgi?id=14383 5 6 * WebKit\Plugin\inc\PluginWin.h: Added CPluginWin::GetPluginUid() 7 * WebKit\Plugin\inc\PluginHandler.h: Added CPluginInfo::Uid() 8 * WebKit\Plugin\inc\PluginSkin.h: Added CPluginSkin::IsPluginScriptableL() 9 * WebKit\Plugin\src\PluginSkin.cpp: 10 (CPluginSkin::IsPluginScriptableL()) 11 * WebKit\Plugin\src\PluginWin.cpp: 12 (CPluginWin::GetPluginUid()) 13 1 14 2007-08-08 yadavall <sriram.yadavalli> 2 15 -
S60/branches/3.1m/WebKit/Plugin/inc/PluginHandler.h
r20908 r24955 474 474 void ParseDefaultDataL(const TDesC8& aMIMEDescription); 475 475 void ParseDisplayNameL(const TDesC& aPluginDescription); 476 476 TInt32 Uid() { return iUid.iUid; } 477 477 private: // Private Methods 478 478 -
S60/branches/3.1m/WebKit/Plugin/inc/PluginSkin.h
r24940 r24955 388 388 void *PluginScriptableObject(); 389 389 390 /** 391 * Checks if plugin UID is present in the repository 392 * Checks if Plugin is scriptable 393 * @since 3.1 394 * @returns True if plugin is scriptable, Flase otherwise 395 */ 396 TInt IsPluginScriptableL(); 397 390 398 public: // Functions from MViewFocusObserver 391 399 -
S60/branches/3.1m/WebKit/Plugin/inc/PluginWin.h
r21537 r24955 502 502 void *PluginScriptableObject(); 503 503 504 /** 505 * Get plugin UID 506 * @since 3.1 507 * @return 508 */ 509 TInt32 CPluginWin::GetPluginUid(); 510 504 511 protected: // New functions 505 512 -
S60/branches/3.1m/WebKit/Plugin/src/PluginSkin.cpp
r24940 r24955 79 79 _LIT(KContentTypeFlash, "flash"); 80 80 81 const TUint KOrigBufSize = 512; 81 82 // The default placeholder width, matches the value set in html4.css 82 83 const TUint KPlaceholderWidth( 100 ); … … 702 703 #endif 703 704 705 // ----------------------------------------------------------------------------- 706 // CPluginSkin::IsPluginScriptableL 707 // ----------------------------------------------------------------------------- 708 // 709 TInt CPluginSkin::IsPluginScriptableL() 710 { 711 // If the plugin content hasnt arrived yet or plugin is invalid, then return immediately 712 if ( !iPluginWin ) 713 { 714 return KErrNotFound; 715 } 716 717 // Allocate wide buffer for data types 718 HBufC* uid = HBufC::NewLC( KOrigBufSize ); 719 TPtr uidPtr( uid->Des() ); 720 TInt error; 721 722 #ifndef __BROWSER_SDK 723 CRepository* rep = CRepository::NewL( KCRUidBrowser ); 724 #else 725 CRepository* rep = CRepository::NewL( KCRUidWebUi ); 726 #endif 727 CleanupStack::PushL( rep ); 728 729 // Read the data types from repository, increase the buffer 730 // if the initial size not enough. 731 error = rep->Get( KPluginScriptabilityAllowed, uidPtr ); 732 733 if( error == KErrOverflow ) 734 { 735 // retry with a bigger buffer 736 do 737 { 738 uid->ReAllocL( uidPtr.MaxLength() + KOrigBufSize ); 739 uidPtr.Set( uid->Des() ); 740 741 error = rep->Get( KPluginScriptabilityAllowed, uidPtr ); 742 } 743 while( error == KErrOverflow ); 744 } 745 746 //Integer to String; 747 TBuf16 <12> uidString; 748 uidString.Num(iPluginWin->GetPluginUid(), EHex); 749 error = uid->FindC(uidString); 750 751 CleanupStack::PopAndDestroy( 2 ); // uidPtr, rep 752 753 return error; 754 } 755 704 756 void* CPluginSkin::PluginScriptableObject() 705 757 { 758 TInt isScriptable; 759 706 760 CWidgetExtension* wdgtExt = iWebKitFrame->WebKitView().WebKitControl().WidgetExtension(); 707 if (wdgtExt) 708 { 761 762 if (!wdgtExt) 763 TRAPD(err, (isScriptable = IsPluginScriptableL())); 764 765 if(wdgtExt || (!err && !isScriptable)) { 709 766 return iPluginWin?iPluginWin->PluginScriptableObject():0; 710 767 } -
S60/branches/3.1m/WebKit/Plugin/src/PluginWin.cpp
r21537 r24955 1254 1254 iTopUrl = aUrl.AllocL(); 1255 1255 } 1256 1257 // ----------------------------------------------------------------------------- 1258 // CPluginWin::GetPluginUid 1259 // ----------------------------------------------------------------------------- 1260 // 1261 TInt32 CPluginWin::GetPluginUid() 1262 { 1263 RPointerArray<CPluginInfo> pluginInfoArray = iPluginHandler->PluginInfoArray(); 1264 TInt index = iPluginHandler->GetIndexFromHandle(iHandle); 1265 CPluginInfo* plugin = pluginInfoArray[index]; 1266 return plugin->Uid(); 1267 } 1268 1256 1269 // ----------------------------------------------------------------------------- 1257 1270 // CPluginData::CPluginData
Note: See TracChangeset
for help on using the changeset viewer.