blob: 77f6f8f98c50a7d633f0d64dca931dc3ea9c0d4b [file] [log] [blame]
// Copyright 2019 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_BROWSER_ANDROID_TAB_BROWSER_CONTROLS_CONSTRAINTS_HELPER_H_
#define CHROME_BROWSER_ANDROID_TAB_BROWSER_CONTROLS_CONSTRAINTS_HELPER_H_
#include "base/android/scoped_java_ref.h"
// Dispatches changes to the browser controls constraints for a given tab.
class TabBrowserControlsConstraintsHelper {
public:
TabBrowserControlsConstraintsHelper(
JNIEnv* env,
const base::android::JavaParamRef<jobject>& obj);
~TabBrowserControlsConstraintsHelper();
void UpdateState(JNIEnv* env,
const base::android::JavaParamRef<jobject>& obj,
const base::android::JavaParamRef<jobject>& jweb_contents,
jint constraints,
jint current,
jboolean animate);
void OnDestroyed(JNIEnv* env,
const base::android::JavaParamRef<jobject>& obj);
private:
base::android::ScopedJavaGlobalRef<jobject> jobj_;
};
#endif // CHROME_BROWSER_ANDROID_TAB_BROWSER_CONTROLS_CONSTRAINTS_HELPER_H_