本文整理汇总了C++中platformDestroy函数的典型用法代码示例。如果您正苦于以下问题:C++ platformDestroy函数的具体用法?C++ platformDestroy怎么用?C++ platformDestroy使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了platformDestroy函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: platformDestroy
void Gradient::addColorStop(const Gradient::ColorStop& stop)
{
m_stops.append(stop);
m_stopsSorted = false;
platformDestroy();
}
示例2: platformDestroy
FontData::~FontData()
{
platformDestroy();
// We only get deleted when the cache gets cleared. Since the smallCapsRenderer is also in that cache,
// it will be deleted then, so we don't need to do anything here.
}
示例3: ENABLE
SimpleFontData::~SimpleFontData()
{
#if ENABLE(SVG_FONTS)
if (!m_fontData)
#endif
platformDestroy();
if (!isCustomFont())
GlyphPageTreeNode::pruneTreeFontData(this);
}
示例4: ENABLE
SimpleFontData::~SimpleFontData()
{
#if ENABLE(SVG_FONTS)
if (!m_svgFontData || !m_svgFontData->svgFontFaceElement())
#endif
platformDestroy();
if (!isCustomFont())
GlyphPageTreeNode::pruneTreeFontData(this);
}
示例5: platformDestroy
void Gradient::addColorStop(float value, const Color& color)
{
m_stops.append(ColorStop(value,
color.red() / 255.0f,
color.green() / 255.0f,
color.blue() / 255.0f,
color.alpha() / 255.0f));
m_stopsSorted = false;
platformDestroy();
}
示例6: ENABLE
SimpleFontData::~SimpleFontData()
{
#if ENABLE(SVG_FONTS)
if (!m_svgFontData || !m_svgFontData->svgFontFaceElement())
#endif
platformDestroy();
if (!isCustomFont()) {
if (m_smallCapsFontData)
fontCache()->releaseFontData(m_smallCapsFontData);
GlyphPageTreeNode::pruneTreeFontData(this);
}
}
示例7: platformDestroy
cairo_pattern_t* Gradient::platformGradient(float globalAlpha)
{
if (m_gradient && m_platformGradientAlpha == globalAlpha)
return m_gradient;
platformDestroy();
m_platformGradientAlpha = globalAlpha;
if (m_radial)
m_gradient = cairo_pattern_create_radial(m_p0.x(), m_p0.y(), m_r0, m_p1.x(), m_p1.y(), m_r1);
else
m_gradient = cairo_pattern_create_linear(m_p0.x(), m_p0.y(), m_p1.x(), m_p1.y());
Vector<ColorStop>::iterator stopIterator = m_stops.begin();
while (stopIterator != m_stops.end()) {
#if !PLATFORM(JS) || USE(ACCELERATED_COMPOSITING)
cairo_pattern_add_color_stop_rgba(m_gradient, stopIterator->stop,
stopIterator->red, stopIterator->green, stopIterator->blue,
stopIterator->alpha * globalAlpha);
#else
// Swap the RGBA channels, canvas painting needs to be ARGB
// but since the channels come out backwards as ABGR we just
// swap the red and blue to get the same channel format without
// haveing to go through all of the pixels and swap them post-blit.
cairo_pattern_add_color_stop_rgba(m_gradient, stopIterator->stop,
stopIterator->blue, stopIterator->green, stopIterator->red,
stopIterator->alpha * globalAlpha);
#endif
++stopIterator;
}
switch (m_spreadMethod) {
case SpreadMethodPad:
cairo_pattern_set_extend(m_gradient, CAIRO_EXTEND_PAD);
break;
case SpreadMethodReflect:
cairo_pattern_set_extend(m_gradient, CAIRO_EXTEND_REFLECT);
break;
case SpreadMethodRepeat:
cairo_pattern_set_extend(m_gradient, CAIRO_EXTEND_REPEAT);
break;
}
cairo_matrix_t matrix = m_gradientSpaceTransformation;
cairo_matrix_invert(&matrix);
cairo_pattern_set_matrix(m_gradient, &matrix);
return m_gradient;
}
示例8: platformDestroy
void Gradient::addColorStop(float value, const Color& color)
{
// FIXME: ExtendedColor - update this to support colors with color spaces.
float r;
float g;
float b;
float a;
color.getRGBA(r, g, b, a);
m_stops.append(ColorStop(value, r, g, b, a));
m_stopsSorted = false;
platformDestroy();
invalidateHash();
}
示例9: ENABLE
SimpleFontData::~SimpleFontData()
{
#if ENABLE(SVG_FONTS)
if (!m_fontData)
#endif
platformDestroy();
if (!isCustomFont())
GlyphPageTreeNode::pruneTreeFontData(this);
//+EAWebKitChange - There have been cases where a glyph can render yet the prune for custom fonts has
// not yet been called. This can cause a rare crash since the simpleFontData has now been destroyed.
//2/19/2013
else
GlyphPageTreeNode::pruneTreeCustomFontData(this);
//-EAWebKitChange
}
示例10: ASSERT
void NetscapePlugin::destroy()
{
ASSERT(m_isStarted);
// Stop all streams.
stopAllStreams();
#if !PLUGIN_ARCHITECTURE(MAC)
m_npWindow.window = 0;
callSetWindow();
#endif
NPP_Destroy(0);
m_isStarted = false;
m_pluginController = 0;
platformDestroy();
}
示例11: ASSERT
void PluginControllerProxy::destroy()
{
ASSERT(m_plugin);
if (m_pluginDestructionProtectCount) {
// We have plug-in code on the stack so we can't destroy it right now.
// Destroy it later.
m_shouldDestroyPluginWhenCountReachesZero = true;
return;
}
m_plugin->destroy();
m_plugin = 0;
platformDestroy();
// This will delete the plug-in controller proxy object.
m_connection->removePluginControllerProxy(this);
}
示例12: platformDestroy
cairo_pattern_t* Gradient::platformGradient(float globalAlpha)
{
if (m_gradient && m_platformGradientAlpha == globalAlpha)
return m_gradient;
platformDestroy();
m_platformGradientAlpha = globalAlpha;
if (m_radial)
m_gradient = cairo_pattern_create_radial(m_p0.x(), m_p0.y(), m_r0, m_p1.x(), m_p1.y(), m_r1);
else
m_gradient = cairo_pattern_create_linear(m_p0.x(), m_p0.y(), m_p1.x(), m_p1.y());
Vector<ColorStop>::iterator stopIterator = m_stops.begin();
while (stopIterator != m_stops.end()) {
cairo_pattern_add_color_stop_rgba(m_gradient, stopIterator->stop,
stopIterator->red, stopIterator->green, stopIterator->blue,
stopIterator->alpha * globalAlpha);
++stopIterator;
}
switch (m_spreadMethod) {
case SpreadMethodPad:
cairo_pattern_set_extend(m_gradient, CAIRO_EXTEND_PAD);
break;
case SpreadMethodReflect:
cairo_pattern_set_extend(m_gradient, CAIRO_EXTEND_REFLECT);
break;
case SpreadMethodRepeat:
cairo_pattern_set_extend(m_gradient, CAIRO_EXTEND_REPEAT);
break;
}
cairo_matrix_t matrix = m_gradientSpaceTransformation;
cairo_matrix_invert(&matrix);
cairo_pattern_set_matrix(m_gradient, &matrix);
return m_gradient;
}
示例13: ASSERT
void PluginControllerProxy::destroy()
{
ASSERT(m_plugin);
if (m_pluginDestructionProtectCount) {
// We have plug-in code on the stack so we can't destroy it right now.
// Destroy it later.
m_pluginDestroyTimer.startOneShot(0);
return;
}
// Get the plug-in so we can pass it to removePluginControllerProxy. The pointer is only
// used as an identifier so it's OK to just get a weak reference.
Plugin* plugin = m_plugin.get();
m_plugin->destroyPlugin();
m_plugin = 0;
platformDestroy();
// This will delete the plug-in controller proxy object.
m_connection->removePluginControllerProxy(this, plugin);
}
示例14: ASSERT
GraphicsContext::~GraphicsContext()
{
ASSERT(m_stack.isEmpty());
ASSERT(!m_transparencyCount);
platformDestroy();
}
示例15: platformDestroy
Gradient::~Gradient()
{
platformDestroy();
}