Discussion Board

Results 1 to 10 of 10
  1. #1
    Registered User EagleSW's Avatar
    Join Date
    Sep 2007
    Posts
    8
    Hello.

    I have developed app which open FlashLite movie by CDocumentHandler::OpenFileEmbeddedL.
    App will be run in landscape orientation always.
    I wrote code:
    PHP Code:
    void CFlashAppUi::ConstructL()
    {
    BaseConstructL(CAknAppUi::EAknEnableSkin CAknAppUi::EAppOrientationLandscape);
    // ...
    // SetOrientationL(CAknAppUiBase::EAppUiOrientationLandscape);
    iAppView CFlashAppView::NewL(ApplicationRect());
    // SetOrientationL(CAknAppUiBase::EAppUiOrientationLandscape);

    CFlashAppView has member CDocumentHandler and open Flash in ConstructL method:

    PHP Code:
    void CFlashAppView::ConstructL(const TRectaRect)
    {
        
    CreateWindowL();
        
    SetExtentToWholeScreen();
        
    ActivateL();
        
    StartFlash();

    StartFlash() method's code:
    PHP Code:
    void CFlashAppView::StartFlash()
    {
    _LIT(KLitSwfFileToLaunch"\\Other\\flash.swf");
    TFileName fileName(KLitSwfFileToLaunch);
    CompleteWithAppPath(fileName);

    RFs fs;
    RFile sh_file;
    User::LeaveIfError(fs.Connect());
    CleanupClosePushL(fs);
    User::LeaveIfError(fs.ShareProtected());
    User::LeaveIfError(sh_file.Open(fsKLitSwfFileToLaunchEFileShareReadersOnly));
    CleanupClosePushL(sh_file);
            
    iHandler CDocumentHandler::NewL((CEikProcess*)iEikonEnv->Process());
    iHandler->SetExitObserver(this);
    TDataType dType;
    iHandler->OpenFileEmbeddedL(sh_filedType);

    CleanupStack::PopAndDestroy(2); // fs, sh_file

    I see app created in landscape orientation, but flash - in portrait
    I tried insert "SetOrientationL(CAknAppUiBase::EAppUiOrientationLandscape)" before and after creating AppView, but it doesn't help.
    If i use slider - app and flash change orientation normally.

    How i can force open flash in landscape orientation?
    Thanks.

    p.s.> Nokia N95.

  2. #2
    Nokia Developer Moderator skumar_rao's Avatar
    Join Date
    Mar 2004
    Location
    Singapore
    Posts
    9,968
    Just a Quick question are you able to Play Flash Player in Landscape Mode. If no then it may not be supported in Flash Player which i doubt.

  3. #3
    Registered User EagleSW's Avatar
    Join Date
    Sep 2007
    Posts
    8
    Quote Originally Posted by skumar_rao View Post
    Just a Quick question are you able to Play Flash Player in Landscape Mode. If no then it may not be supported in Flash Player which i doubt.
    Yes, Flash Player can play in landscape mode. If i use slider - flash with my app change orientation.

    BTW, anybody knows key event codes for capturing slider? I can't determinate exactly codes from TKeyEvent & TStdKeyEvent.

  4. #4
    Registered User EagleSW's Avatar
    Join Date
    Sep 2007
    Posts
    8
    Hello again!
    Some questions yet:

    - How can i rotate whole screen instead AppUI?
    - How can i simulate slider events for embedded flash player?

  5. #5
    Registered User 2olivia's Avatar
    Join Date
    Sep 2007
    Location
    Malaysia
    Posts
    17
    u use microbrowser to embeded the flash lite? or are u using symbian C++?

  6. #6
    Registered User EagleSW's Avatar
    Join Date
    Sep 2007
    Posts
    8
    Quote Originally Posted by 2olivia View Post
    u use microbrowser to embeded the flash lite? or are u using symbian C++?
    I used Symbian SDK C++ and i found solution!

    I found key events for slider, it's EKeyDevice8,9,A,B.
    For rotating screen in landscape mode i simulated key event EKeyDeviceA and immediately after - EKeyDevice8.
    EKeyDeviceB & EKeyDevice9 - for portait mode.

  7. #7
    Regular Contributor Jii5Hoo's Avatar
    Join Date
    Jan 2008
    Posts
    56
    Thats interesting,

    Little discrete info: we have used also Nokia Sensor API to follow phone rotation(tilt) to get correct orientation in Flash Lite dynamically.

  8. #8
    Registered User shimel1's Avatar
    Join Date
    Jan 2010
    Posts
    18
    Hi,

    I am using flash_ui.dll (http://www.forum.nokia.com/document/...sh__ui_8h.html) to lounch Flash stub application. There is no AppUi, so please tell me how to force the application to work only in landscape mode.

  9. #9
    Nokia Developer Champion sajisoft's Avatar
    Join Date
    Jul 2008
    Location
    Pakistan
    Posts
    1,062
    According to my observation, you cannot force the Flash Stub application to work in landscape mode only through Symbian C++ SetOrientationL API because it doesnt have any affect when u embed the flash content in Symbian C++ application and u cannot use it if u r using flash_ui.dll solution. However, there are some workarounds, if u using Flash lite 3.1 :
    Setting the default orientation for flash app(Read post # 11)

    Best Regards,
    SajiSoft

  10. #10
    Registered User shimel1's Avatar
    Join Date
    Jan 2010
    Posts
    18
    Thanks Saji,

    i assumed that orientation controlling is not possible, so I simply show the animation inside swf which asks user to switch device into landscape mode and than disable autoRotation. It is not an elegant solution, but it should be ok. Thanks anyway for workaround advice.

    Regards,
    Simon

Similar Threads

  1. Welcome to Flash Lite Discussion
    By Nokia Ron in forum Qt
    Replies: 21
    Last Post: 2011-06-07, 12:22
  2. Flash Lite 101, a new mobile technology
    By UbiquityGames in forum Mobile Java General
    Replies: 0
    Last Post: 2006-09-30, 21:22
  3. Flash Lite 1.1 use on Mobile
    By mathi77in in forum Mobile Java Media (Graphics & Sounds)
    Replies: 2
    Last Post: 2006-02-08, 19:13
  4. Preinstalled Flash Lite support in Nseries phones (N70, N90)?
    By Kipt in forum General Development Questions
    Replies: 3
    Last Post: 2006-02-08, 19:09
  5. S60 2nd FP3 and 3rd - Flash Lite frustration
    By ilyadanilov in forum General Development Questions
    Replies: 7
    Last Post: 2006-02-08, 19:07

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved