mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-08 10:51:03 +00:00
use auto_ptr
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24347 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
eb987d20db
commit
25c08b9345
@ -53,8 +53,7 @@
|
|||||||
#include <objidl.h>
|
#include <objidl.h>
|
||||||
#endif // Q_WS_WIN
|
#endif // Q_WS_WIN
|
||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <memory>
|
||||||
|
|
||||||
#include <map>
|
#include <map>
|
||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
@ -171,7 +170,7 @@ QVector<FORMATETC> QWindowsMimeMetafile::formatsForMime(
|
|||||||
return formats;
|
return formats;
|
||||||
}
|
}
|
||||||
|
|
||||||
static boost::shared_ptr<QWindowsMimeMetafile> metafileWindowsMime;
|
static std::auto_ptr<QWindowsMimeMetafile> metafileWindowsMime;
|
||||||
|
|
||||||
#endif // Q_WS_WIN
|
#endif // Q_WS_WIN
|
||||||
|
|
||||||
@ -236,7 +235,7 @@ QList<QByteArray> QMacPasteboardMimeGraphics::convertFromMime(QString const & mi
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
static boost::shared_ptr<QMacPasteboardMimeGraphics> graphicsPasteboardMime;
|
static std::auto_ptr<QMacPasteboardMimeGraphics> graphicsPasteboardMime;
|
||||||
|
|
||||||
#endif // Q_WS_MACX
|
#endif // Q_WS_MACX
|
||||||
|
|
||||||
@ -249,17 +248,13 @@ GuiClipboard::GuiClipboard()
|
|||||||
on_dataChanged();
|
on_dataChanged();
|
||||||
|
|
||||||
#ifdef Q_WS_MACX
|
#ifdef Q_WS_MACX
|
||||||
if (!graphicsPasteboardMime)
|
if (!graphicsPasteboardMime.get())
|
||||||
graphicsPasteboardMime =
|
graphicsPasteboardMime.reset(new QMacPasteboardMimeGraphics());
|
||||||
boost::shared_ptr<QMacPasteboardMimeGraphics>
|
|
||||||
(new QMacPasteboardMimeGraphics());
|
|
||||||
#endif // Q_WS_MACX
|
#endif // Q_WS_MACX
|
||||||
|
|
||||||
#ifdef Q_WS_WIN
|
#ifdef Q_WS_WIN
|
||||||
if (!metafileWindowsMime)
|
if (!metafileWindowsMime.get())
|
||||||
metafileWindowsMime =
|
metafileWindowsMime.reset(new QWindowsMimeMetafile());
|
||||||
boost::shared_ptr<QWindowsMimeMetafile>
|
|
||||||
(new QWindowsMimeMetafile());
|
|
||||||
#endif // Q_WS_WIN
|
#endif // Q_WS_WIN
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user