00001 /* 00002 =. This file is part of the OPIE Project 00003 .=l. Copyright (c) 2002 Maximilian Reiss <max.reiss@gmx.de> 00004 .>+-= 00005 _;:, .> :=|. This library is free software; you can 00006 .> <, > . <= redistribute it and/or modify it under 00007 :=1 )Y*s>-.-- : the terms of the GNU Library General Public 00008 .="- .-=="i, .._ License as published by the Free Software 00009 - . .-<_> .<> Foundation; either version 2 of the License, 00010 ._= =} : or (at your option) any later version. 00011 .%+i> _;_. 00012 .i_,=:_. -<s. This library is distributed in the hope that 00013 + . -:. = it will be useful, but WITHOUT ANY WARRANTY; 00014 : .. .:, . . . without even the implied warranty of 00015 =_ + =;=| MERCHANTABILITY or FITNESS FOR A 00016 _.=:. : :=>: PARTICULAR PURPOSE. See the GNU 00017 ..}^=.= = ; Library General Public License for more 00018 ++= -. . .: details. 00019 : = ...= . :.=- 00020 -. .:....=;==+<; You should have received a copy of the GNU 00021 -_. . . )=. = Library General Public License along with 00022 -- :-= this library; see the file COPYING.LIB. 00023 If not, write to the Free Software Foundation, 00024 Inc., 59 Temple Place - Suite 330, 00025 Boston, MA 02111-1307, USA. 00026 00027 */ 00028 00029 #include "opietoothapplet.h" 00030 #include "opietoothappletimpl.h" 00031 00032 namespace Opietooth2 { 00033 00034 BluezAppletImpl::BluezAppletImpl() : bluetooth(0), ref(0) { 00035 } 00036 00037 BluezAppletImpl::~BluezAppletImpl() { 00038 delete bluetooth; 00039 } 00040 00041 QWidget *BluezAppletImpl::applet( QWidget *parent ) { 00042 if ( !bluetooth ) { 00043 bluetooth = new Opietooth2Applet( parent ); 00044 } 00045 return bluetooth; 00046 } 00047 00048 int BluezAppletImpl::position() const { 00049 return 6; 00050 } 00051 00052 QRESULT BluezAppletImpl::queryInterface( const QUuid &uuid, QUnknownInterface **iface ) { 00053 *iface = 0; 00054 if ( uuid == IID_QUnknown ) { 00055 *iface = this; 00056 } else if ( uuid == IID_TaskbarApplet ) { 00057 *iface = this; 00058 } 00059 00060 if ( *iface ) { 00061 (*iface)->addRef(); 00062 } 00063 return QS_OK; 00064 } 00065 00066 Q_EXPORT_INTERFACE() { 00067 Q_CREATE_INSTANCE( BluezAppletImpl ) 00068 } 00069 00070 }; 00071 00072
1.4.2