From 758badf800f49c7db3ca2ee81afd1e885ae97da5 Mon Sep 17 00:00:00 2001 From: trialuser02 Date: Sat, 18 Sep 2010 10:02:13 +0000 Subject: switching to QLocalServer and QLocalSocket git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@1890 90c681e8-e032-0410-971d-27865f9a5e38 --- src/ui/unixdomainsocket.h | 69 ----------------------------------------------- 1 file changed, 69 deletions(-) delete mode 100644 src/ui/unixdomainsocket.h (limited to 'src/ui/unixdomainsocket.h') diff --git a/src/ui/unixdomainsocket.h b/src/ui/unixdomainsocket.h deleted file mode 100644 index f9bfa73e8..000000000 --- a/src/ui/unixdomainsocket.h +++ /dev/null @@ -1,69 +0,0 @@ -/*************************************************************************** - * Copyright (C) 2008 by Ilya Kotov * - * forkotov02@hotmail.ru * - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - * This program is distributed in the hope that it will be useful, * - * but WITHOUT ANY WARRANTY; without even the implied warranty of * - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * - * GNU General Public License for more details. * - * * - * You should have received a copy of the GNU General Public License * - * along with this program; if not, write to the * - * Free Software Foundation, Inc., * - * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * - ***************************************************************************/ - -#ifndef UNIXDOMAINSOCKET_H -#define UNIXDOMAINSOCKET_H - -#include -#include -#include -#include -#ifdef Q_OS_LINUX -#include -#else -#include -#endif - -/*! - * UnixDomainSocket class is a wrapper around the unix domain sockets implementation. - * Used for QMMP interprocess communications. - * @author Vladimir Kuznetsov - */ -class UnixDomainSocket : public QUdpSocket -{ -Q_OBJECT -public: - UnixDomainSocket(QObject * parent = 0 ); - - /*! - * Try to bind socket to \b path. Returns \b true on success, otherwise \b false - */ - bool bind(const QString& file); - - /*! - * Checks if socket at \b path path is alive( i.e. connectable). - */ - bool alive(const QString& path); - ~UnixDomainSocket(); - -public slots: - /*! - * Sends the datagram \b command to the socket at \b path path. - */ - void writeDatagram(const char* command,const QString& path); -private: - unsigned int _s; - struct sockaddr_un _local; - bool _bound; -}; - - -#endif - -- cgit v1.2.3-13-gbd6f