mirror of
https://github.com/cefsharp/CefSharp.git
synced 2026-12-05 03:32:37 +00:00
46 lines
1.0 KiB
C++
46 lines
1.0 KiB
C++
// Copyright © 2010-2015 The CefSharp Project. All rights reserved.
|
|
//
|
|
// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
|
|
|
|
#pragma once
|
|
|
|
#include "Stdafx.h"
|
|
|
|
using namespace System::Diagnostics;
|
|
|
|
namespace CefSharp
|
|
{
|
|
namespace Internals
|
|
{
|
|
public ref class CefWrapper abstract
|
|
{
|
|
protected:
|
|
bool _disposed;
|
|
|
|
void ThrowIfDisposed()
|
|
{
|
|
if (_disposed)
|
|
{
|
|
auto type = GetType();
|
|
|
|
throw gcnew ObjectDisposedException(gcnew String(L"This instance of " + type->GetInterfaces()[0]->FullName + " been disposed!"));
|
|
}
|
|
}
|
|
|
|
public:
|
|
CefWrapper() : _disposed(false)
|
|
{
|
|
|
|
};
|
|
|
|
virtual property bool IsDisposed
|
|
{
|
|
bool get()
|
|
{
|
|
return _disposed;
|
|
}
|
|
}
|
|
};
|
|
}
|
|
}
|