From 05debe1d787b7471c2bc9c8f7569a338ca5c7ad4 Mon Sep 17 00:00:00 2001 From: Mathias Agopian Date: Wed, 8 Feb 2017 17:04:18 -0800 Subject: Split view::Surface out of Surface.cpp MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit it’s moved into a new view/Surface.cpp, header in gui/view/Surface.h their entanglement also meant that code that needs only view::Surface ended up with all of Surface dependencies. Test: built and booted device Bug: treble Change-Id: I1a350d258f124fbe0a7bc5a2ca165311dcb0d8e3 --- include/gui/Surface.h | 41 +---------------------------------------- 1 file changed, 1 insertion(+), 40 deletions(-) (limited to 'include/gui/Surface.h') diff --git a/include/gui/Surface.h b/include/gui/Surface.h index 60203f7c4f..c3014b2696 100644 --- a/include/gui/Surface.h +++ b/include/gui/Surface.h @@ -17,8 +17,6 @@ #ifndef ANDROID_GUI_SURFACE_H #define ANDROID_GUI_SURFACE_H -#include - #include #include @@ -410,43 +408,6 @@ protected: std::unique_ptr mFrameEventHistory; }; -namespace view { - -/** - * A simple holder for an IGraphicBufferProducer, to match the managed-side - * android.view.Surface parcelable behavior. - * - * This implements android/view/Surface.aidl - * - * TODO: Convert IGraphicBufferProducer into AIDL so that it can be directly - * used in managed Binder calls. - */ -class Surface : public Parcelable { - public: - - String16 name; - sp graphicBufferProducer; - - virtual status_t writeToParcel(Parcel* parcel) const override; - virtual status_t readFromParcel(const Parcel* parcel) override; - - // nameAlreadyWritten set to true by Surface.java, because it splits - // Parceling itself between managed and native code, so it only wants a part - // of the full parceling to happen on its native side. - status_t writeToParcel(Parcel* parcel, bool nameAlreadyWritten) const; - - // nameAlreadyRead set to true by Surface.java, because it splits - // Parceling itself between managed and native code, so it only wants a part - // of the full parceling to happen on its native side. - status_t readFromParcel(const Parcel* parcel, bool nameAlreadyRead); - - private: - - static String16 readMaybeEmptyString16(const Parcel* parcel); -}; - -} // namespace view - -}; // namespace android +} // namespace android #endif // ANDROID_GUI_SURFACE_H -- cgit v1.2.3-59-g8ed1b