亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? css_value.cpp

?? It is WEB browser core module with source code. Very good!
?? CPP
字號:
/**
 * This file is part of the DOM implementation for KDE.
 *
 * (C) 1999 Lars Knoll (knoll@kde.org)
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Library General Public
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * This library 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
 * Library General Public License for more details.
 *
 * You should have received a copy of the GNU Library General Public License
 * along with this library; see the file COPYING.LIB.  If not, write to
 * the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
 * Boston, MA 02111-1307, USA.
 *
 */

#include "dom/css_rule.h"
#include "dom/dom_exception.h"

#include "css/css_valueimpl.h"

namespace DOM {

CSSStyleDeclaration::CSSStyleDeclaration()
{
    impl = 0;
}

CSSStyleDeclaration::CSSStyleDeclaration(const CSSStyleDeclaration &other)
{
    impl = other.impl;
    if(impl) impl->ref();
}

CSSStyleDeclaration::CSSStyleDeclaration(CSSStyleDeclarationImpl *i)
{
    impl = i;
    if(impl) impl->ref();
}

CSSStyleDeclaration &CSSStyleDeclaration::operator = (const CSSStyleDeclaration &other)
{
    if ( impl != other.impl ) {
    if(impl) impl->deref();
    impl = other.impl;
    if(impl) impl->ref();
    }
    return *this;
}

CSSStyleDeclaration::~CSSStyleDeclaration()
{
    if(impl) impl->deref();
}

DOMString CSSStyleDeclaration::cssText() const
{
    if(!impl) return DOMString();
    return impl->cssText();
}

static void throwException(int exceptioncode)
{
#if KHTML_NO_EXCEPTIONS
    _exceptioncode = exceptioncode;
#else
    if (exceptioncode >= CSSException::_EXCEPTION_OFFSET)
	throw CSSException(exceptioncode - CSSException::_EXCEPTION_OFFSET);
    if (exceptioncode)
	throw DOMException(exceptioncode);
#endif    
}

void CSSStyleDeclaration::setCssText( const DOMString &value )
{
    if(!impl) return;
    int exceptionCode = 0;
    impl->setCssText(value, exceptionCode);
    throwException(exceptionCode);
}

DOMString CSSStyleDeclaration::getPropertyValue( const DOMString &propertyName )
{
    if(!impl) return DOMString();
    int id = getPropertyID(propertyName.string().ascii(), propertyName.length());
    if (!id) return DOMString();
    return impl->getPropertyValue(id);
}

CSSValue CSSStyleDeclaration::getPropertyCSSValue( const DOMString &propertyName )
{
    if(!impl) return 0;
    int id = getPropertyID(propertyName.string().ascii(), propertyName.length());
    if (!id) return 0;
    return impl->getPropertyCSSValue(id);
}

DOMString CSSStyleDeclaration::removeProperty( const DOMString &property )
{
    int id = getPropertyID(property.string().ascii(), property.length());
    if(!impl || !id) return DOMString();
    int exceptionCode = 0;
    DOMString result = impl->removeProperty( id, exceptionCode );
    throwException(exceptionCode);
    return result;
}

DOMString CSSStyleDeclaration::getPropertyPriority( const DOMString &propertyName )
{
    int id = getPropertyID(propertyName.string().ascii(), propertyName.length());
    if(!impl || !id) return DOMString();
    if (impl->getPropertyPriority(id))
        return DOMString("important");
    return DOMString();
}

void CSSStyleDeclaration::setProperty( const DOMString &propName, const DOMString &value, const DOMString &priority )
{
    if(!impl) return;
    int id = getPropertyID(propName.string().lower().ascii(), propName.length());
    if (!id) return;
    bool important = false;
    QString str = priority.string();
    if (str.find("important", 0, false) != -1)
        important = true;

    int exceptionCode;
    impl->setProperty( id, value, important, exceptionCode );
    throwException(exceptionCode);
}

unsigned long CSSStyleDeclaration::length() const
{
    if(!impl) return 0;
    return impl->length();
}

DOMString CSSStyleDeclaration::item( unsigned long index )
{
    if(!impl) return DOMString();
    return impl->item( index );
}

CSSRule CSSStyleDeclaration::parentRule() const
{
    if(!impl) return 0;
    return impl->parentRule();
}

CSSStyleDeclarationImpl *CSSStyleDeclaration::handle() const
{
    return impl;
}

bool CSSStyleDeclaration::isNull() const
{
    return (impl == 0);
}

// ----------------------------------------------------------

CSSValue::CSSValue()
{
    impl = 0;
}

CSSValue::CSSValue(const CSSValue &other)
{
    impl = other.impl;
    if(impl) impl->ref();
}

CSSValue::CSSValue(CSSValueImpl *i)
{
    impl = i;
    if(impl) impl->ref();
}

CSSValue &CSSValue::operator = (const CSSValue &other)
{
    if ( impl != other.impl ) {
    if(impl) impl->deref();
    impl = other.impl;
    if(impl) impl->ref();
    }
    return *this;
}

CSSValue::~CSSValue()
{
    if(impl) impl->deref();
}

DOMString CSSValue::cssText() const
{
    if(!impl) return DOMString();
    return ((CSSValueImpl *)impl)->cssText();
}

void CSSValue::setCssText(const DOMString &)
{
    // ### not implemented
}

unsigned short CSSValue::cssValueType() const
{
    if(!impl) return 0;
    return ((CSSValueImpl *)impl)->cssValueType();
}

bool CSSValue::isCSSValueList() const
{
    if(!impl) return false;
    return ((CSSValueImpl *)impl)->isValueList();
}

bool CSSValue::isCSSPrimitiveValue() const
{
    if(!impl) return false;
    return ((CSSValueImpl *)impl)->isPrimitiveValue();
}

CSSValueImpl *CSSValue::handle() const
{
    return impl;
}

bool CSSValue::isNull() const
{
    return (impl == 0);
}

// ----------------------------------------------------------

CSSValueList::CSSValueList() : CSSValue()
{
}

CSSValueList::CSSValueList(const CSSValueList &other) : CSSValue(other)
{
}

CSSValueList::CSSValueList(const CSSValue &other)
{
   impl = 0;
   operator=(other);
}

CSSValueList::CSSValueList(CSSValueListImpl *impl) : CSSValue(impl)
{
}

CSSValueList &CSSValueList::operator = (const CSSValueList &other)
{
    if ( impl != other.impl ) {
    if (impl) impl->deref();
    impl = other.handle();
    if (impl) impl->ref();
    }
    return *this;
}

CSSValueList &CSSValueList::operator = (const CSSValue &other)
{
    CSSValueImpl *ohandle = other.handle() ;
    if ( impl != ohandle ) {
    if (impl) impl->deref();
    if (!other.isNull() && !other.isCSSValueList()) {
	impl = 0;
	} else {
	    impl = ohandle;
    if (impl) impl->ref();
	}
    }
    return *this;
}

CSSValueList::~CSSValueList()
{
}

unsigned long CSSValueList::length() const
{
    if(!impl) return 0;
    return ((CSSValueListImpl *)impl)->length();
}

CSSValue CSSValueList::item( unsigned long index )
{
    if(!impl) return 0;
    return ((CSSValueListImpl *)impl)->item( index );
}

// ----------------------------------------------------------

CSSPrimitiveValue::CSSPrimitiveValue() : CSSValue()
{
}

CSSPrimitiveValue::CSSPrimitiveValue(const CSSPrimitiveValue &other) : CSSValue(other)
{
}

CSSPrimitiveValue::CSSPrimitiveValue(const CSSValue &other) : CSSValue(other)
{
    impl = 0;
    operator=(other);
}

CSSPrimitiveValue::CSSPrimitiveValue(CSSPrimitiveValueImpl *impl) : CSSValue(impl)
{
}

CSSPrimitiveValue &CSSPrimitiveValue::operator = (const CSSPrimitiveValue &other)
{
    if ( impl != other.impl ) {
    if (impl) impl->deref();
    impl = other.handle();
    if (impl) impl->ref();
    }
    return *this;
}

CSSPrimitiveValue &CSSPrimitiveValue::operator = (const CSSValue &other)
{
    CSSValueImpl *ohandle = other.handle();
    if ( impl != ohandle ) {
    if (impl) impl->deref();
    if (!other.isNull() && !other.isCSSPrimitiveValue()) {
	impl = 0;
	} else {
	    impl = ohandle;
    if (impl) impl->ref();
	}
    }
    return *this;
}

CSSPrimitiveValue::~CSSPrimitiveValue()
{
}

unsigned short CSSPrimitiveValue::primitiveType() const
{
    if(!impl) return 0;
    return ((CSSPrimitiveValueImpl *)impl)->primitiveType();
}

void CSSPrimitiveValue::setFloatValue( unsigned short unitType, float floatValue )
{
    if(!impl) return;
    int exceptioncode = 0;
    ((CSSPrimitiveValueImpl *)impl)->setFloatValue( unitType, floatValue, exceptioncode );
    throwException(exceptioncode);
}

float CSSPrimitiveValue::getFloatValue( unsigned short unitType )
{
    if(!impl) return 0;
    // ### add unit conversion
    if(primitiveType() != unitType)
#if KHTML_NO_EXCEPTIONS
        { _exceptioncode = CSSException::SYNTAX_ERR + CSSException::_EXCEPTION_OFFSET; return 0; }
#else
        throw CSSException(CSSException::SYNTAX_ERR);
#endif  
    return ((CSSPrimitiveValueImpl *)impl)->getFloatValue( unitType );
}

void CSSPrimitiveValue::setStringValue( unsigned short stringType, const DOMString &stringValue )
{
    int exceptioncode = 0;
    if(impl)
        ((CSSPrimitiveValueImpl *)impl)->setStringValue( stringType, stringValue, exceptioncode );
    throwException(exceptioncode);

}

DOMString CSSPrimitiveValue::getStringValue(  )
{
    if(!impl) return DOMString();
    return ((CSSPrimitiveValueImpl *)impl)->getStringValue(  );
}

Counter CSSPrimitiveValue::getCounterValue(  )
{
    if(!impl) return Counter();
    return ((CSSPrimitiveValueImpl *)impl)->getCounterValue(  );
}

Rect CSSPrimitiveValue::getRectValue(  )
{
    if(!impl) return Rect();
    return ((CSSPrimitiveValueImpl *)impl)->getRectValue(  );
}

RGBColor CSSPrimitiveValue::getRGBColorValue(  )
{
    // ###
    return RGBColor();
    //if(!impl) return RGBColor();
    //return ((CSSPrimitiveValueImpl *)impl)->getRGBColorValue(  );
}

// -------------------------------------------------------------------

Counter::Counter()
{
}

Counter::Counter(const Counter &/*other*/)
{
    impl = 0;
}

Counter &Counter::operator = (const Counter &other)
{
    if ( impl != other.impl ) {
    if (impl) impl->deref();
    impl = other.impl;
    if (impl) impl->ref();
    }
    return *this;
}

Counter::Counter(CounterImpl *i)
{
    impl = i;
    if (impl) impl->ref();
}

Counter::~Counter()
{
    if (impl) impl->deref();
}

DOMString Counter::identifier() const
{
  if (!impl) return DOMString();
  return impl->identifier();
}

DOMString Counter::listStyle() const
{
  if (!impl) return DOMString();
  return impl->listStyle();
}

DOMString Counter::separator() const
{
  if (!impl) return DOMString();
  return impl->separator();
}

CounterImpl *Counter::handle() const
{
    return impl;
}

bool Counter::isNull() const
{
    return (impl == 0);
}

// --------------------------------------------------------------------

RGBColor::RGBColor()
{
}

RGBColor::RGBColor(const RGBColor &other)
{
    m_color = other.m_color;
}

RGBColor::RGBColor(const QColor &color)
{
    m_color = color;
}

RGBColor &RGBColor::operator = (const RGBColor &other)
{
    m_color = other.m_color;
    return *this;
}

RGBColor::~RGBColor()
{
}

CSSPrimitiveValue RGBColor::red() const
{
    return new CSSPrimitiveValueImpl((float)m_color.red(), CSSPrimitiveValue::CSS_DIMENSION);
}

CSSPrimitiveValue RGBColor::green() const
{
    return new CSSPrimitiveValueImpl((float)m_color.green(), CSSPrimitiveValue::CSS_DIMENSION);
}

CSSPrimitiveValue RGBColor::blue() const
{
    return new CSSPrimitiveValueImpl((float)m_color.blue(), CSSPrimitiveValue::CSS_DIMENSION);
}


// ---------------------------------------------------------------------

Rect::Rect()
{
    impl = 0;
}

Rect::Rect(const Rect &other)
{
    impl = other.impl;
    if (impl) impl->ref();
}

Rect::Rect(RectImpl *i)
{
    impl = i;
    if (impl) impl->ref();
}

Rect &Rect::operator = (const Rect &other)
{
    if ( impl != other.impl ) {
    if (impl) impl->deref();
    impl = other.impl;
    if (impl) impl->ref();
    }
    return *this;
}

Rect::~Rect()
{
    if (impl) impl->deref();
}

CSSPrimitiveValue Rect::top() const
{
    if (!impl) return 0;
    return impl->top();
}

CSSPrimitiveValue Rect::right() const
{
    if (!impl) return 0;
    return impl->right();
}

CSSPrimitiveValue Rect::bottom() const
{
    if (!impl) return 0;
    return impl->bottom();
}

CSSPrimitiveValue Rect::left() const
{
    if (!impl) return 0;
    return impl->left();
}

RectImpl *Rect::handle() const
{
    return impl;
}

bool Rect::isNull() const
{
    return (impl == 0);
}

} // namespace DOM

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产综合久久久久久鬼色| 欧美一级日韩一级| 欧美精品视频www在线观看| 久久精品欧美一区二区三区不卡| 一区二区三区免费观看| 国产在线精品一区二区| 一本大道综合伊人精品热热| 久久亚洲综合色| 亚洲成人777| 色哟哟国产精品| 国产精品欧美久久久久一区二区| 美女国产一区二区三区| 91官网在线免费观看| 国产精品久久久久天堂| 国内精品在线播放| 欧美一区二区三区在线观看视频| 一区二区三区视频在线观看| 国产成人亚洲精品青草天美| 日韩免费视频线观看| 天堂蜜桃91精品| 欧美性高清videossexo| 亚洲人妖av一区二区| 成人小视频在线| 精品国产露脸精彩对白| 青青草一区二区三区| 制服丝袜成人动漫| 日日欢夜夜爽一区| 欧美日韩亚洲另类| 亚洲国产精品麻豆| 欧美午夜精品电影| 亚洲国产综合在线| 欧美日韩一卡二卡| 丝袜国产日韩另类美女| 欧美浪妇xxxx高跟鞋交| 亚洲国产综合91精品麻豆| 91一区二区三区在线观看| 日韩一区欧美一区| www.99精品| 亚洲男人天堂av| 欧美午夜精品久久久| 亚洲国产精品久久人人爱蜜臀| 精品视频免费在线| 日本中文字幕一区二区有限公司| 91精品国产一区二区三区蜜臀| 午夜欧美电影在线观看| 欧美一区二区三区四区久久| 久久66热偷产精品| 国产拍欧美日韩视频二区| 成人福利电影精品一区二区在线观看| 国产精品国产自产拍高清av| 91麻豆国产福利在线观看| 一区二区不卡在线视频 午夜欧美不卡在| 日韩欧美国产一区在线观看| 极品销魂美女一区二区三区| 国产欧美一区二区在线观看| 成人深夜在线观看| 亚洲乱码一区二区三区在线观看| 欧美日韩大陆一区二区| 激情综合五月天| 亚洲免费观看视频| 欧美一区二区视频在线观看| 国产福利一区二区| 一区二区三区久久久| 欧美一级欧美一级在线播放| 国产成人免费xxxxxxxx| 亚洲一区二区三区四区在线| 日韩精品一区二区三区视频 | 精品少妇一区二区三区日产乱码| 国产一区二区三区精品视频| 成人免费视频在线观看| 51精品国自产在线| 成人免费毛片嘿嘿连载视频| 亚洲永久精品国产| 久久精子c满五个校花| 欧美日韩一区在线| 狠狠色综合色综合网络| 亚洲成a人v欧美综合天堂下载| 久久综合一区二区| 欧美综合一区二区| 国产伦精品一区二区三区在线观看| 一区二区三区加勒比av| 久久亚洲精华国产精华液| 欧美在线免费观看亚洲| 成人少妇影院yyyy| 精品综合免费视频观看| 亚洲成年人影院| 最新国产精品久久精品| 精品99999| 欧美日本在线看| 91色九色蝌蚪| 成人理论电影网| 久久狠狠亚洲综合| 一区二区高清在线| 成人欧美一区二区三区| 欧美激情中文字幕一区二区| 欧美一级日韩不卡播放免费| 欧美在线免费观看视频| 99re这里只有精品视频首页| 国产99一区视频免费| 日韩av一区二| 午夜精品成人在线| 亚洲综合一区二区三区| 中文字幕一区二区三区在线播放| 久久精品夜夜夜夜久久| 精品91自产拍在线观看一区| 欧美一级在线观看| 69堂成人精品免费视频| 欧美日韩在线播放三区四区| 91丝袜美腿高跟国产极品老师 | 国产精品国模大尺度视频| 久久久午夜电影| 欧美大白屁股肥臀xxxxxx| 欧美男女性生活在线直播观看| 色国产综合视频| 91福利社在线观看| 91成人在线精品| 欧美日韩久久一区| 欧美日韩精品一区二区三区四区 | 欧美日本韩国一区二区三区视频 | 97aⅴ精品视频一二三区| 成人高清av在线| 91在线一区二区| 成人精品鲁一区一区二区| 顶级嫩模精品视频在线看| 岛国精品一区二区| av不卡免费电影| 色综合久久综合| 欧美性一区二区| 在线不卡中文字幕播放| 日韩午夜三级在线| 国产网站一区二区| 中文字幕综合网| 亚洲福利视频导航| 日本最新不卡在线| 国产伦精品一区二区三区免费| 成人性生交大片免费| 在线观看网站黄不卡| 欧美肥妇bbw| 久久精品视频一区二区| 成人免费在线视频观看| 午夜激情综合网| 国产永久精品大片wwwapp| 97精品电影院| 91精品国产欧美一区二区18| 久久精品亚洲一区二区三区浴池 | 免费精品视频在线| 丁香天五香天堂综合| 91成人免费电影| 精品久久久三级丝袜| 中文字幕一区二区在线观看| 亚洲bt欧美bt精品| 激情成人综合网| 在线观看91视频| 亚洲精品在线免费播放| 国产精品成人免费在线| 日韩av在线发布| 本田岬高潮一区二区三区| 欧美精品777| 中文字幕一区av| 麻豆国产精品官网| 在线看不卡av| 国产欧美精品一区aⅴ影院| 亚洲一卡二卡三卡四卡五卡| 国产一区二区三区四区五区入口| 在线观看成人小视频| 国产视频一区二区在线观看| 亚洲成a人v欧美综合天堂| 成人免费va视频| 日韩免费高清视频| 午夜免费久久看| 不卡视频一二三四| 久久久99久久| 久久99精品视频| 欧美亚洲一区二区在线| 欧美国产激情二区三区| 热久久国产精品| 欧美午夜一区二区三区| 国产精品久久久久桃色tv| 国产麻豆视频一区| 日韩三级免费观看| 午夜一区二区三区在线观看| youjizz久久| 精品裸体舞一区二区三区| 亚洲高清免费观看 | 国产福利不卡视频| 91精品国产乱| 五月婷婷久久丁香| 在线观看亚洲成人| 一区二区三区四区激情| 91网上在线视频| 国产精品高潮呻吟| jiyouzz国产精品久久| 久久精品亚洲一区二区三区浴池| 久久精品av麻豆的观看方式| 欧美久久久久久久久| 午夜精品福利一区二区三区av| 欧美撒尿777hd撒尿| 亚洲综合丁香婷婷六月香| 91传媒视频在线播放| 亚洲综合免费观看高清在线观看|