2017-10-27 20:33:53 +03:00
|
|
|
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
|
|
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
|
2012-10-01 20:49:41 +04:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
|
|
|
|
/* DOM object representing values in DOM computed style */
|
|
|
|
|
|
|
|
#ifndef mozilla_dom_CSSValue_h_
|
|
|
|
#define mozilla_dom_CSSValue_h_
|
|
|
|
|
|
|
|
#include "nsWrapperCache.h"
|
2014-05-09 19:23:14 +04:00
|
|
|
#include "nsStringFwd.h"
|
2012-10-01 20:49:41 +04:00
|
|
|
|
|
|
|
class nsROCSSPrimitiveValue;
|
2014-05-09 19:23:14 +04:00
|
|
|
namespace mozilla {
|
|
|
|
class ErrorResult;
|
2015-07-13 18:25:42 +03:00
|
|
|
} // namespace mozilla
|
2012-10-01 20:49:41 +04:00
|
|
|
|
|
|
|
namespace mozilla {
|
|
|
|
namespace dom {
|
|
|
|
|
|
|
|
/**
|
|
|
|
* CSSValue - a DOM object representing values in DOM computed style.
|
|
|
|
*/
|
|
|
|
class CSSValue : public nsISupports,
|
|
|
|
public nsWrapperCache
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
// CSSValue
|
|
|
|
virtual void GetCssText(nsString& aText, mozilla::ErrorResult& aRv) = 0;
|
|
|
|
virtual void SetCssText(const nsAString& aText, mozilla::ErrorResult& aRv) = 0;
|
|
|
|
virtual uint16_t CssValueType() const = 0;
|
2012-10-25 03:38:52 +04:00
|
|
|
|
|
|
|
// Downcasting
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Return this as a nsROCSSPrimitiveValue* if its a primitive value, and null
|
|
|
|
* otherwise.
|
2018-01-11 11:17:57 +03:00
|
|
|
*
|
|
|
|
* Defined in nsROCSSPrimitiveValue.h.
|
2012-10-25 03:38:52 +04:00
|
|
|
*/
|
2018-01-11 11:17:57 +03:00
|
|
|
inline nsROCSSPrimitiveValue* AsPrimitiveValue();
|
2012-10-01 20:49:41 +04:00
|
|
|
};
|
|
|
|
|
2015-07-13 18:25:42 +03:00
|
|
|
} // namespace dom
|
|
|
|
} // namespace mozilla
|
2012-10-01 20:49:41 +04:00
|
|
|
|
|
|
|
#endif
|