Changeset 17793 in webkit
- Timestamp:
- Nov 15, 2006 2:34:54 PM (18 years ago)
- Location:
- S60/trunk/WebKit
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
S60/trunk/WebKit/BrowserControl/inc/BrCtlDefs.h
r17517 r17793 207 207 ECommandSmartLinkSendMessage, ///< 208 208 ECommandSmartLinkAddToPhoneBook, ///< 209 ECommandShowToolBar, ///<Shows the toolbar 210 ECommandDisableFlash, ///<Enable/Disable the flash 209 ECommandShowToolBar ///<Shows the toolbar 211 210 }; 212 211 /** … … 448 447 ESettingsSavedPage, ///< Save the page 449 448 ESettingsSmartLink, 450 ESettingsAutoOpenDownloads, // For automatically open the downloaded files 449 ESettingsAutoOpenDownloads, // For automatically open the downloaded files 450 ESettingsDisableFlash, ///<Enable/Disable the flash 451 451 ESettingsMaxEnum ///< Must be last one 452 452 }; -
S60/trunk/WebKit/BrowserView/inc/BrowserSettingsContainer.h
r17706 r17793 77 77 #endif 78 78 const TBool KDefaultESettingsAutoOpenDownloads = ETrue; 79 const TBool KDefaultESettingsDisableFlash = EFalse; 80 79 81 80 82 const TInt KDefaultESettingsApId = 0; -
S60/trunk/WebKit/BrowserView/inc/WebKitControl.h
r17517 r17793 239 239 public: // New functions 240 240 241 /**242 * WebKitView243 * Return WebKitView object244 * @since 3.x241 /** 242 * WebKitView 243 * Return WebKitView object 244 * @since 3.x 245 245 * @return WebKitView object 246 */246 */ 247 247 CWebKitView& WebKitView() const { return *iWebKitView; } 248 248 … … 281 281 HBufC* PageInfoLC( TBrCtlDefs::TBrCtlPageInfo aBrCtlPageInfo ); 282 282 283 /**283 /** 284 284 * LoadSavedPageL 285 285 * Parse and load the page data supplied via the buffer … … 289 289 void LoadSavedPageL( const TDesC& aUid, TDesC& aSavedPageBuffer ); 290 290 291 /**292 * HandleLoaderCommandL293 * Handle the commands related to resource loader294 * @since 3.x295 * @return void 296 */297 void HandleLoaderCommandL( TInt aCommand );291 /** 292 * HandleLoaderCommandL 293 * Handle the commands related to resource loader 294 * @since 3.x 295 * @return void 296 */ 297 void HandleLoaderCommandL( TInt aCommand ); 298 298 299 299 /** … … 306 306 307 307 308 /**308 /** 309 309 * CreateWindow 310 310 * Purpose … … 335 335 CWebKitView* FindWindowNamed(const TDesC& aFrameName); 336 336 337 /**337 /** 338 338 * DelegateWindowCommand 339 339 * From MWebClientBridge … … 342 342 * @param TBrCtlWindowCommand window command 343 343 */ 344 void DelegateWindowCommand(TBrCtlWindowCommand aCommand);345 346 /**344 void DelegateWindowCommand(TBrCtlWindowCommand aCommand); 345 346 /** 347 347 * Start DataLoad 348 348 * Load the data … … 350 350 * @return void 351 351 */ 352 TInt StartDataLoadL( const TDesC& aUrl, CDataLoadInfo& aDataLoadInfo );353 354 /**352 TInt StartDataLoadL( const TDesC& aUrl, CDataLoadInfo& aDataLoadInfo ); 353 354 /** 355 355 * IsUrlInCache 356 356 * Ask the Browser Control if a URL is in cache … … 386 386 TPtrC UserAgentStringL(); 387 387 388 /**389 * return history controller390 * @return history controller391 */388 /** 389 * return history controller 390 * @return history controller 391 */ 392 392 CHistoryController& HistoryController() const { return *iHistoryController; } 393 393 394 /**395 * HistoryLength396 * @return the number of entries in the history list397 */394 /** 395 * HistoryLength 396 * @return the number of entries in the history list 397 */ 398 398 TInt HistoryLength() const; 399 399 400 /**401 * HandleHistoryCommandL402 * Handle the commands related to history object403 * @since 3.x404 * @return void 405 */406 void HandleHistoryCommandL( TInt aCommand );407 408 /**409 * ClearHistoryList410 * Clears History List411 * @since 3.x412 * @return void 413 */400 /** 401 * HandleHistoryCommandL 402 * Handle the commands related to history object 403 * @since 3.x 404 * @return void 405 */ 406 void HandleHistoryCommandL( TInt aCommand ); 407 408 /** 409 * ClearHistoryList 410 * Clears History List 411 * @since 3.x 412 * @return void 413 */ 414 414 void ClearHistoryList(); 415 415 416 /**417 * GoBackOrForward418 * Load url from history + or - distance from current page419 * @return void420 */421 void GoBackOrForward( TInt aDistance );416 /** 417 * GoBackOrForward 418 * Load url from history + or - distance from current page 419 * @return void 420 */ 421 void GoBackOrForward( TInt aDistance ); 422 422 423 423 /** … … 428 428 TBool CanGoBackOrForward( TInt aDistance ); 429 429 430 /**431 * NavigationAvailable432 * Determine if Back and Forward navigation options should be visible433 * @since 3.x434 * @return TBool - ETrue if direction is visible435 */436 TBool NavigationAvailable( TBrCtlDefs::TBrCtlNavigationDirection aDirection );430 /** 431 * NavigationAvailable 432 * Determine if Back and Forward navigation options should be visible 433 * @since 3.x 434 * @return TBool - ETrue if direction is visible 435 */ 436 TBool NavigationAvailable( TBrCtlDefs::TBrCtlNavigationDirection aDirection ); 437 437 438 438 /** … … 441 441 * return CArrayFixFlat 442 442 */ 443 CArrayFixFlat<TBrCtlImageCarrier>* PageImagesL();443 CArrayFixFlat<TBrCtlImageCarrier>* PageImagesL(); 444 444 445 445 /** … … 448 448 * return void 449 449 */ 450 void LoadImages();450 void LoadImages(); 451 451 452 452 /** … … 465 465 */ 466 466 CPluginHandler& PluginHandler() const { 467 return (CStaticObjectContainer::Instance().PluginHandlerL(*iBrCtl)); }468 469 /** 470 * Requests a pointer to the Zoom Level array maintained by the webkit view471 * @since 3.0472 * @return A pointer to the zoom levels array467 return (CStaticObjectContainer::Instance().PluginHandlerL(*iBrCtl)); } 468 469 /** 470 * Requests a pointer to the Zoom Level array maintained by the webkit view 471 * @since 3.0 472 * @return A pointer to the zoom levels array 473 473 */ 474 474 RArray<TUint>* ZoomLevels() const; … … 493 493 494 494 495 /**495 /** 496 496 * Retrive the image count of the rectangle 497 497 * 498 498 */ 499 TInt ImageCount() const;499 TInt ImageCount() const; 500 500 501 501 … … 545 545 return (CStaticObjectContainer::Instance().FormDataManagerHandlerL(*iBrCtl)); } 546 546 547 /**547 /** 548 548 * PluginResized 549 549 * This will relayout the rendering objects, because the plugin was resized … … 551 551 * return void 552 552 */ 553 void PluginResized();553 void PluginResized(); 554 554 555 555 /** … … 589 589 590 590 /** 591 * ProgressUpdate592 *593 * @since 3.x594 * @return void 595 */591 * ProgressUpdate 592 * 593 * @since 3.x 594 * @return void 595 */ 596 596 void ProgressUpdate(); 597 597 … … 706 706 * @return access point id 707 707 */ 708 TUint32 AccessPointId() { return iApId; }708 TUint32 AccessPointId() { return iApId; } 709 709 710 710 … … 714 714 * @return 715 715 */ 716 void SetAccessPointId(TUint32 aApId) { iApId = aApId; }716 void SetAccessPointId(TUint32 aApId) { iApId = aApId; } 717 717 718 718 /* … … 729 729 */ 730 730 void ForegroundEvent(TBool aForeground); 731 732 733 /** 734 * DisableFlashSetting 735 * 736 * @since 3.2 737 * @return TBool 738 */ 739 740 741 TBool DisableFlashSetting() { return iDisableFlash; } 742 731 743 732 744 733 #ifdef RD_32_BROWSER … … 791 780 void ConstructL(); 792 781 793 /**782 /** 794 783 * ShowHistoryViewL 795 784 * 796 785 * @since 3.x 797 786 * @return void 798 */787 */ 799 788 void ShowHistoryViewL(TBool aPrevious); 800 789 801 /**802 * ShowHistoryListL803 *804 * @since 3.x805 * @return void 806 */790 /** 791 * ShowHistoryListL 792 * 793 * @since 3.x 794 * @return void 795 */ 807 796 void ShowHistoryListL(); 808 797 809 /**810 * LoadHistoryEntry811 *812 * @since 3.x813 * @return void 814 */798 /** 799 * LoadHistoryEntry 800 * 801 * @since 3.x 802 * @return void 803 */ 815 804 void LoadHistoryEntry( CArrayFixFlat<TBrCtlSelectOptionData>& aHistoryList ); 816 805 817 /**818 * InitializeWebCoreL819 *820 * @since 3.x821 * @return void 822 */806 /** 807 * InitializeWebCoreL 808 * 809 * @since 3.x 810 * @return void 811 */ 823 812 void InitializeWebCoreL(); 824 813 825 /**826 * InitializeSettingsL827 *828 * @since 3.x829 * @return void 830 */814 /** 815 * InitializeSettingsL 816 * 817 * @since 3.x 818 * @return void 819 */ 831 820 void InitializeSettingsL(); 832 821 833 /**834 * LoadResourceFileL835 *836 * @since 3.x837 * @return void 838 */822 /** 823 * LoadResourceFileL 824 * 825 * @since 3.x 826 * @return void 827 */ 839 828 void LoadResourceFileL(); 840 829 … … 848 837 849 838 /** 850 * ResetProgress851 *852 * @since 3.x853 * @return void 854 */839 * ResetProgress 840 * 841 * @since 3.x 842 * @return void 843 */ 855 844 void ResetProgress(); 856 845 857 846 /** 858 * FinalProgressComplete859 *860 * @since 3.x861 * @return void 862 */847 * FinalProgressComplete 848 * 849 * @since 3.x 850 * @return void 851 */ 863 852 void FinalProgressComplete(); 864 853 865 854 /** 866 * CheckForCancelComplete867 *868 * @since 3.x869 * @return void 870 */855 * CheckForCancelComplete 856 * 857 * @since 3.x 858 * @return void 859 */ 871 860 void CheckForCancelComplete(); 872 861 873 874 void HandleDisableFlashSetting( TBool aFlashValue, TBool aImageValue );875 862 876 863 private: // Data … … 922 909 TInt iInitialProgressPercentage; 923 910 924 // access point id that is used for connection925 TInt32 iApId;911 // access point id that is used for connection 912 TInt32 iApId; 926 913 // true if application is in the background 927 914 TBool iSuspendTimers; 928 915 929 //Settings to store value of the Flash Disable930 TBool iDisableFlash;931 932 916 #ifdef RD_32_BROWSER 933 917 // plugin player -
S60/trunk/WebKit/BrowserView/src/BrowserSettingsContainer.cpp
r17706 r17793 295 295 #endif 296 296 SettingL( TBrCtlDefs::ESettingsAutoOpenDownloads ).SetBoolValueL( KDefaultESettingsAutoOpenDownloads ); 297 SettingL( TBrCtlDefs::ESettingsDisableFlash ).SetBoolValueL( KDefaultESettingsDisableFlash ); 297 298 } 298 299 -
S60/trunk/WebKit/BrowserView/src/WebKitControl.cpp
r17706 r17793 530 530 iGenerateSavedPage(ETrue), 531 531 iHeaderArrived(EFalse), 532 iInitialProgressPercentage( KMinInitialProgressPercentage ), 533 iDisableFlash (ETrue) 532 iInitialProgressPercentage( KMinInitialProgressPercentage ) 534 533 { 535 534 iProgressNotificationInterval = 0.02; … … 638 637 } 639 638 640 641 // -----------------------------------------------------------------------------642 // CWebKitControl::HandleDisableFlashSetting643 // Private Class Method644 //-------------------------------------------------645 void CWebKitControl::HandleDisableFlashSetting( TBool aFlashValue, TBool aImageValue )646 {647 648 649 if ( ( !aFlashValue ) && aImageValue )650 {651 //Enable the flash loading652 //AutoImage loading is enable(ETrue) and aFlashValue is enable(EFalse)653 iDisableFlash = EFalse; //Means enable the flash loading654 }655 else if( (!aImageValue) )656 {657 //Disable the flash loading658 //AutoImage loading is disabled(EFalse). Don't care about the659 //new value of the flash aFlashValue as image loading is being660 //disabled.661 iDisableFlash = ETrue; //Means disable the flash loading662 }663 else if( aFlashValue && aImageValue )664 {665 //Disable the flash loading666 iDisableFlash = ETrue; //Means disable the flash loading667 }668 669 //To do: Need to remove following line when UI check in their670 //changes. Till then keep the flash loading on.671 iDisableFlash = EFalse;672 }//end CWebKitControl::HandleDisableFlashSetting()673 674 675 639 676 640 // ----------------------------------------------------------------------------- … … 703 667 #endif 704 668 case TBrCtlDefs::ESettingsAutoOpenDownloads: 669 case TBrCtlDefs::ESettingsDisableFlash: 705 670 { 706 671 TBool val( aValue ); 707 672 iBrowserSettingsContainer->SettingL( TBrCtlDefs::TBrCtlSettings( 708 673 aSetting )).SetBoolValueL( val ); 709 if( aSetting == TBrCtlDefs::ESettingsAutoLoadImages )710 {711 HandleDisableFlashSetting( iDisableFlash, val );712 }713 674 break; 714 675 } … … 748 709 iHistoryController->SetHistoryViewEnabled(aValue); 749 710 } 750 case TBrCtlDefs::ECommandDisableFlash:751 {752 TBool autoLoadImages = ETrue;753 if( iBrowserSettingsContainer )754 {755 autoLoadImages = iBrowserSettingsContainer->SettingL(756 TBrCtlDefs::TBrCtlSettings(TBrCtlDefs::ESettingsAutoLoadImages) ).BoolValue();757 758 }759 HandleDisableFlashSetting( aValue, autoLoadImages );760 break;761 }762 711 default: 763 712 { … … 798 747 #endif 799 748 case TBrCtlDefs::ESettingsAutoOpenDownloads: 749 case TBrCtlDefs::ESettingsDisableFlash: 800 750 { 801 751 retVal = (TUint)iBrowserSettingsContainer->SettingL( … … 842 792 break; 843 793 } 844 case TBrCtlDefs::ECommandDisableFlash:845 {846 retVal = ( TUint ) iDisableFlash;847 break;848 }849 794 default: 850 795 { -
S60/trunk/WebKit/ChangeLog
r17790 r17793 1 2006-11-08 spadma <Sachin.Padma@nokia.com> 2 3 Reviewed by Yongjun. 4 DESC: [S60] Modify Autoload Images and Objects setting to include enabling/disabling of flash. 5 http://bugs.webkit.org/show_bug.cgi?id=11605 6 7 * BrowserControl/inc/BrCtlDefs.h: 8 (TBrCtlDefs::): 9 * BrowserView/inc/BrowserSettingsContainer.h: 10 * BrowserView/inc/WebKitControl.h: 11 (CWebKitControl::PluginHandler): 12 (CWebKitControl::AccessPointId): 13 (CWebKitControl::SetAccessPointId): 14 * BrowserView/src/BrowserSettingsContainer.cpp: 15 (CBrowserSettingsContainer::InsertDefaultSettingsL): 16 * BrowserView/src/WebKitControl.cpp: 17 (CWebKitControl::CWebKitControl): 18 (CWebKitControl::SetBrowserSettingL): 19 (CWebKitControl::GetBrowserSettingL): 20 * Plugin/src/PluginSkin.cpp: 21 (CPluginSkin::NewL): 22 (CPluginSkin::ConstructL): 23 1 24 2006-11-15 spadma <Sachin.Padma@nokia.com> 2 25 -
S60/trunk/WebKit/Plugin/src/PluginSkin.cpp
r17517 r17793 111 111 112 112 //Check if the flash plugin is enabled or disabled. 113 if( ( aMIMEType.Find(KContentTypeFlash) != KErrNotFound ) &&114 ( aWebKitFrame.WebKitView().WebKitControl().DisableFlashSetting() ) )115 {116 self = NULL;117 }118 else119 {120 113 self = new (ELeave) CPluginSkin( aWebKitFrame ); 121 114 CleanupStack::PushL( self ); … … 123 116 aUrl, aBaseUrl, aCanPluginInteract ); 124 117 CleanupStack::Pop(); // self 125 }126 118 return self; 127 119 } … … 256 248 else 257 249 { 250 TBool loadPluginContent = iWebKitFrame->WebKitView().WebKitControl().GetBrowserSettingL( TBrCtlDefs::ESettingsAutoLoadImages ); 251 252 if( ( aMIMEType.Find(KContentTypeFlash) != KErrNotFound ) ) 253 { 254 loadPluginContent = loadPluginContent && !iWebKitFrame->WebKitView().WebKitControl().GetBrowserSettingL( TBrCtlDefs::ESettingsDisableFlash ); 255 } 256 258 257 // After UI CR for adding setting for plugin, use the ESetting AutoLoadPlugins 259 if ( iWebKitFrame->WebKitView().WebKitControl().GetBrowserSettingL( TBrCtlDefs::ESettingsAutoLoadImages ))258 if ( loadPluginContent ) 260 259 { 261 260 // Load the plugin content NOW since autoload is ON and the phone is non-US build
Note: See TracChangeset
for help on using the changeset viewer.