lazy_background_page_native_handler.h 901 B

12345678910111213141516171819202122232425
  1. // Copyright 2014 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #ifndef EXTENSIONS_RENDERER_LAZY_BACKGROUND_PAGE_NATIVE_HANDLER_H_
  5. #define EXTENSIONS_RENDERER_LAZY_BACKGROUND_PAGE_NATIVE_HANDLER_H_
  6. #include "extensions/renderer/object_backed_native_handler.h"
  7. #include "v8/include/v8-forward.h"
  8. namespace extensions {
  9. class LazyBackgroundPageNativeHandler : public ObjectBackedNativeHandler {
  10. public:
  11. explicit LazyBackgroundPageNativeHandler(ScriptContext* context);
  12. void IncrementKeepaliveCount(const v8::FunctionCallbackInfo<v8::Value>& args);
  13. void DecrementKeepaliveCount(const v8::FunctionCallbackInfo<v8::Value>& args);
  14. // ObjectBackedNativeHandler:
  15. void AddRoutes() override;
  16. };
  17. } // namespace extensions
  18. #endif // EXTENSIONS_RENDERER_LAZY_BACKGROUND_PAGE_NATIVE_HANDLER_H_