bluetoothengine/btui/btuidelegate/btdelegatedisconnect.h
changeset 31 a0ea99b6fa53
child 40 997690c3397a
child 42 b72428996822
equal deleted inserted replaced
30:df7a93ede42e 31:a0ea99b6fa53
       
     1 /*
       
     2 * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description: 
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef BTDELEGATEDISCONNECT_H
       
    19 #define BTDELEGATEDISCONNECT_H
       
    20 
       
    21 #include <e32base.h>
       
    22 #include <btengconnman.h>
       
    23 #include "btabstractdelegate.h"
       
    24 
       
    25 class BtuiModel;
       
    26 
       
    27 /*!
       
    28     \class BtDelegateDisconnect
       
    29     \brief the base class for Disconnecting Bluetooth Connection.
       
    30  */
       
    31 class BtDelegateDisconnect : public BtAbstractDelegate,
       
    32         public MBTEngConnObserver
       
    33 {
       
    34     Q_OBJECT
       
    35 
       
    36 public:
       
    37     explicit BtDelegateDisconnect(            
       
    38             BtSettingModel* settingModel, 
       
    39             BtDeviceModel* deviceModel, QObject *parent = 0 );
       
    40     
       
    41     virtual ~BtDelegateDisconnect();
       
    42 
       
    43     virtual void exec( const QVariant &params );
       
    44     
       
    45     virtual void cancel();
       
    46     
       
    47 public slots:
       
    48 
       
    49 protected:
       
    50     //From MBTEngConnObserver
       
    51     virtual void ConnectComplete( TBTDevAddr& aAddr, TInt aErr, 
       
    52                                    RBTDevAddrArray* aConflicts );
       
    53     virtual void DisconnectComplete( TBTDevAddr& aAddr, TInt aErr );
       
    54     virtual void PairingComplete( TBTDevAddr& aAddr, TInt aErr );
       
    55 
       
    56     void emitCommandComplete(int error);
       
    57     
       
    58 private:
       
    59 
       
    60     CBTEngConnMan *mBtengConnMan;
       
    61 
       
    62     TBTDevAddr mBtEngddr;
       
    63     
       
    64     QString mdeviceName;
       
    65     
       
    66     Q_DISABLE_COPY(BtDelegateDisconnect)
       
    67 
       
    68 };
       
    69 
       
    70 
       
    71 
       
    72 #endif /* BTDELEGATEDISCONNECT_H */