initial commit

This commit is contained in:
mikhail "synzr" 2025-12-25 01:37:49 +05:00
commit 9d20827c46
2469 changed files with 470994 additions and 0 deletions

97
src/infodlg.h Normal file
View file

@ -0,0 +1,97 @@
/*
* infodlg.h - handle vcard
* Copyright (C) 2001, 2002 Justin Karneges
*
* 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 library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
#ifndef INFODLG_H
#define INFODLG_H
// #ifdef YAPSI
// #include "ui_yainfo.h"
// #else
#include "ui_info.h"
// #endif
#ifdef YAPSI
#include "yawindow.h"
#include "yawindowtheme.h"
#endif
namespace XMPP
{
class Jid;
class VCard;
class Resource;
}
using namespace XMPP;
class PsiAccount;
class InfoDlg : public YaWindow
{
Q_OBJECT
public:
enum { Self, Contact };
InfoDlg(int type, const XMPP::Jid &, const XMPP::VCard &, PsiAccount *, QWidget *parent=0, bool cacheVCard = true);
~InfoDlg();
// reimplemented
virtual const YaWindowTheme& theme() const;
protected:
// reimplemented
//void closeEvent(QCloseEvent *);
void updatePhoto();
public slots:
void doRefresh();
void updateStatus();
void closeEvent ( QCloseEvent * e );
void setStatusVisibility(bool visible);
private slots:
void contactAvailable(const Jid &, const Resource &);
void contactUnavailable(const Jid &, const Resource &);
void contactUpdated(const Jid &);
void clientVersionFinished();
void requestLastActivityFinished();
void jt_finished();
void doSubmit();
void textChanged();
void selectPhoto();
void clearPhoto();
private:
class Private;
Private *d;
Ui::Info ui_;
YaWindowTheme theme_;
void setData(const XMPP::VCard &);
XMPP::VCard makeVCard();
void fieldsEnable(bool);
void setReadOnly(bool);
bool edited();
void setEdited(bool);
void setPreviewPhoto(const QString& str);
void requestClientVersion(const XMPP::Jid& j);
void requestLastActivity();
};
#endif