×

Discussion Board

Results 1 to 1 of 1
  1. #1
    Registered User
    Join Date
    Jan 2006
    Posts
    14

    CBA is overwritted by previous CBA

    help, I'm having a strange problem with my CBA. The situation is
    1. I have a View class from CAknView, and 3 sets of softkey groups, "Option-Connect", "Option-Cancel" and "Option-Done", the default one is "Option-Connect". When a user select "Connect",my application will start and the "Cancel" will replace "Connect",and when the job is done, the "Cancel" will be replaced by "Done".

    2. I make this works by using CEikButtonGroupContainer::SetCommandSetL().

    3. Problem happend when a user select "Connect", the "Cancel" has replaced "Connect",then a notes or progress dialog popup.After the dialog is dismissed, and job is done, I can see the "Done" is showup but overwrite by "cancel" immediately. But if there is no such dialog, everything is fine. In summary, after a view goes from foreground to background, it seems that it will keep current CBA, then when goes from background to foreground, it will restore the previous CBA.

    4. Here is some pieces of code
    Resource file
    ...
    RESOURCE CBA r_vpn_mgr_base_container_control_pane
    {
    buttons =
    {
    CBA_BUTTON
    {
    id = EAknSoftkeyOptions;
    txt = STR_VpnMgrBaseContainerView_3;
    },
    CBA_BUTTON
    {
    id = EAknSoftkeyOk;
    txt = STR_VpnMgrBaseContainerView_4;
    }
    };
    }

    RESOURCE CBA r_vpn_mgr_base_container_control_pane_disconnect
    {
    buttons =
    {
    CBA_BUTTON
    {
    id = EAknSoftkeyOptions;
    txt = STR_VpnMgrBaseContainerView_3;
    },
    CBA_BUTTON
    {
    id = EAknSoftkeyClose;
    txt = STR_VpnMgrBaseContainerView_19;
    }
    };
    }

    RESOURCE CBA r_vpn_mgr_base_container_control_pane_cancel
    {
    buttons =
    {
    CBA_BUTTON
    {
    id = EAknSoftkeyOptions;
    txt = STR_VpnMgrBaseContainerView_3;
    },
    CBA_BUTTON
    {
    id = EAknSoftkeyCancel;
    txt = STR_VpnMgrBaseContainerView_20;
    }
    };
    }
    ...

    Source code in view class:
    ...
    switch (currentState)
    case EConnecting:
    cba->SetCommandSetL(R_VPN_MGR_BASE_CONTAINER_CONTROL_PANE_CANCEL);
    break;
    case EConnected:
    cba->SetCommandSetL(R_VPN_MGR_BASE_CONTAINER_CONTROL_PANE_DISCONNECT);
    break;
    ...

    }
    ...
    Last edited by j_b_luo; 2008-03-28 at 17:53.

Similar Threads

  1. some problem in firmware 6680 V 5.04.07
    By man2007 in forum Symbian
    Replies: 1
    Last Post: 2007-01-26, 17:36
  2. netcards - Problem with opening adapter
    By kernj in forum Symbian Tools & SDKs
    Replies: 5
    Last Post: 2007-01-10, 08:56
  3. Problem: S60 SDK for CW in PC with .NET
    By anttij in forum Carbide.c++ IDE and plug-ins (Closed)
    Replies: 1
    Last Post: 2005-02-28, 11:36
  4. About 6230 Bt Problem
    By eerkek in forum Bluetooth Technology
    Replies: 17
    Last Post: 2005-02-08, 12:33
  5. 7210 Silent Problem
    By MarkMckim in forum Mobile Java General
    Replies: 1
    Last Post: 2003-03-18, 12:36

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×