• Home
  • History
  • Annotate
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1  /*
2   * Copyright (C) 2013 The Android Open Source Project
3   *
4   * Licensed under the Apache License, Version 2.0 (the "License");
5   * you may not use this file except in compliance with the License.
6   * You may obtain a copy of the License at
7   *
8   *      http://www.apache.org/licenses/LICENSE-2.0
9   *
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  
17  package com.android.camera.filmstrip;
18  
19  import com.android.camera.widget.FilmstripLayout;
20  
21  /**
22   * The filmstrip panel holding the filmstrip and other controls/widgets.
23   */
24  public interface FilmstripContentPanel {
25      /**
26       * An listener interface extending {@link
27       * com.android.camera.filmstrip.FilmstripController.FilmstripListener} defining extra callbacks
28       * for filmstrip being shown and hidden.
29       */
30      interface Listener extends FilmstripController.FilmstripListener {
31  
32          /**
33           * Callback on a swipe out of filmstrip.
34           */
onSwipeOut()35          public void onSwipeOut();
36  
37          /**
38           * Callback on a swiping out begins.
39           */
onSwipeOutBegin()40          public void onSwipeOutBegin();
41  
42          /**
43           * Callback when the filmstrip becomes invisible or gone.
44           */
onFilmstripHidden()45          public void onFilmstripHidden();
46  
47          /**
48           * Callback when the filmstrip is shown in full-screen.
49           */
onFilmstripShown()50          public void onFilmstripShown();
51      }
52  
53      /** Sets the listener. */
setFilmstripListener(FilmstripLayout.Listener listener)54      void setFilmstripListener(FilmstripLayout.Listener listener);
55  
56      /**
57       * Hides this panel with animation.
58       *
59       * @return {@code false} if already hidden.
60       */
animateHide()61      boolean animateHide();
62  
63      /** Hides this panel */
hide()64      void hide();
65  
66      /** Shows this panel */
show()67      void show();
68  
69      /**
70       * Called when the back key is pressed.
71       *
72       * @return Whether the UI responded to the key event.
73       */
onBackPressed()74      boolean onBackPressed();
75  }
76