[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    koffice/kexi/koproperty2 (silent)
From:       Jaroslaw Staniek <js () iidea ! pl>
Date:       2008-10-31 21:27:50
Message-ID: 1225488470.133820.12171.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 878313 by staniek:

SVN_SILENT removed commentedout code that's moved elsewhere


 M  +0 -148    EditorView.cpp  
 M  +0 -54     EditorView.h  


--- trunk/koffice/kexi/koproperty2/EditorView.cpp #878312:878313
@@ -44,156 +44,8 @@
                 defaultAutoSync : (property->autoSync() != 0);
 }
 
-/*
-static const char RECTEDIT_MASK[] = "%1,%2 %3x%4";
-
-RectEdit2::RectEdit2(QWidget *parent)
- : QLabel(parent)
-{
-    setTextInteractionFlags(Qt::TextSelectableByMouse);
-}
-
-RectEdit2::~RectEdit2()
-{
-}
-
-QRect RectEdit2::value() const
-{
-    return m_rect;
-}
-
-void RectEdit2::setValue(const QRect& value)
-{
-    m_rect = value;
-    setText(QString::fromLatin1(RECTEDIT_MASK)
-        .arg(value.x())
-        .arg(value.y())
-        .arg(value.width())
-        .arg(value.height()));
-    setToolTip(i18n("Position: %1, %2\nSize: %3 x %4")
-        .arg(value.x())
-        .arg(value.y())
-        .arg(value.width())
-        .arg(value.height()));
-}*/
-
-/* old
-class StringEdit : public QWidget
-{
-    rmQ_OBJECT
-    Q_PROPERTY(QString value READ value WRITE setValue USER true)
-public:
-    StringEdit(QWidget *parent = 0);
-    ~StringEdit();
-    QString value() const;
-    void setValue(const QString& value);
-private:
-    QLineEdit *m_editor;
-};
-
-StringEdit::StringEdit(QWidget *parent)
- : QWidget(parent)
-{
-    QVBoxLayout *lyr = new QVBoxLayout(this);
-    m_editor = new QLineEdit(this);
-    m_editor->setFrame(false);
-    lyr->setContentsMargins(0,0,0,0);
-    lyr->addWidget(m_editor);
-    setFocusProxy(m_editor);
-//    setStyleSheet("border: 2px solid gray;");
-}
-
-StringEdit::~StringEdit()
-{
-}
-
-QString StringEdit::value() const
-{
-    return m_editor->text();
-}
-
-void StringEdit::setValue(const QString& value)
-{
-    m_editor->setText(value);
-    m_editor->deselect();
-    m_editor->end(false);
-}*/
-
-/*
-StringEdit2::StringEdit2(QWidget *parent)
- : KLineEdit(parent)
- , m_slotTextChangedEnabled(true)
-{
-    setFrame(false);
-    setContentsMargins(0,0,0,0);
-    setClearButtonShown(true);
-    connect(this, SIGNAL(textChanged(const QString&)), this, SLOT(slotTextChanged(const QString&)));
-}
-
-StringEdit2::~StringEdit2()
-{
-}
-
-QString StringEdit2::value() const
-{
-    return text();
-}
-
-void StringEdit2::setValue(const QString& value)
-{
-    m_slotTextChangedEnabled = false;
-    setText(value);
-    m_slotTextChangedEnabled = true;
-//    deselect();
-//    end(false);
-}
-
-void StringEdit2::slotTextChanged( const QString & text )
-{
-    Q_UNUSED(text)
-    if (!m_slotTextChangedEnabled)
-        return;
-    emit commitData(this);
-}
-*/
-
 //----------
 
-/*
-template<class T>
-ItemEditorCreator : public QStandardItemEditorCreator<T>
-{
-public:
-    ItemEditorCreator(
-};*/
-
-/*
-ItemEditorFactory::ItemEditorFactory()
- : QObject()
- , QItemEditorFactory()
-{
-     QItemEditorCreatorBase *creator = new QStandardItemEditorCreator<RectEdit2>();
-     registerEditor(QVariant::Rect, creator);
-     creator = new QStandardItemEditorCreator<StringEdit2>();
-     registerEditor(QVariant::String, creator);
-     creator = new QStandardItemEditorCreator<StringEdit2>();
-     registerEditor(QVariant::Color, creator);
-}
-
-ItemEditorFactory::~ItemEditorFactory()
-{
-}
-
-QWidget* ItemEditorFactory::createEditor( QVariant::Type type, QWidget * parent ) const
-{
-    QWidget *w = QItemEditorFactory::createEditor(type, parent);
-//    QObject::connect(w, SIGNAL(commitData(QWidget*)),
-//        this, SIGNAL(commitData(QWidget*)));
-    return w;
-}*/
-
-//----------
-
 class ItemDelegate : public QItemDelegate
 {
 public:
--- trunk/koffice/kexi/koproperty2/EditorView.h #878312:878313
@@ -20,20 +20,6 @@
 #ifndef KPROPERTY_EDITORVIEW_H
 #define KPROPERTY_EDITORVIEW_H
 
-/*
-#include <QPointer>
-//Added by qt3to4:
-#include <QMouseEvent>
-#include <QResizeEvent>
-#include <QKeyEvent>
-#include <QEvent>
-#include <QByteArray>
-#include "koproperty_global.h"
-
-#include <k3listview.h>
-
-class QSize;*/
-
 #include "koproperty_export.h"
 
 #include <QtGui/QItemEditorFactory>
@@ -47,46 +33,6 @@
 
 class Set;
 
-/*
-class RectEdit2 : public QLabel
-{
-    Q_OBJECT
-    Q_PROPERTY(QRect value READ value WRITE setValue USER true)
-public:
-    RectEdit2(QWidget *parent = 0);
-    ~RectEdit2();
-    QRect value() const;
-    void setValue(const QRect& value);
-private:
-    QRect m_rect;
-};
-
-class StringEdit2 : public KLineEdit
-{
-    Q_OBJECT
-    Q_PROPERTY(QString value READ value WRITE setValue USER true)
-public:
-    StringEdit2(QWidget *parent = 0);
-    ~StringEdit2();
-    QString value() const;
-    void setValue(const QString& value);
-signals:
-    void commitData( QWidget * editor );
-private slots:
-    void slotTextChanged( const QString & text );
-private:
-    bool m_slotTextChangedEnabled : 1;
-};*/
-
-/*
-class Factory2 : public QItemEditorFactory
-{
-    Q_OBJECT
-public:
-    Factory2();
-    virtual ~Factory2();
-};*/
-
 //! @brief A widget for editing properties
 //! @todo review this .............
 /*! Editor widgets use property options using Property::option(const char *)
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic