Home | History | Annotate | Download | only in util
      1 /*
      2  * Copyright (C) 2014 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 
     18 package com.android.camera.util;
     19 
     20 import android.content.Context;
     21 
     22 import com.android.camera.exif.ExifInterface;
     23 import com.android.camera.ui.TouchCoordinate;
     24 
     25 import java.util.HashMap;
     26 
     27 public class UsageStatistics {
     28     public static final long VIEW_TIMEOUT_MILLIS = 0;
     29     public static final int NONE = -1;
     30 
     31     private static UsageStatistics sInstance;
     32 
     33     public static UsageStatistics instance() {
     34         if (sInstance == null) {
     35             sInstance = new UsageStatistics();
     36         }
     37         return sInstance;
     38     }
     39 
     40     public void initialize(Context context) {
     41     }
     42 
     43     public void mediaInteraction(String ref, int interactionType, int cause, float age) {
     44     }
     45 
     46     public void mediaView(String ref, long modifiedMillis, float zoom) {
     47     }
     48 
     49     public void foregrounded(int source, int mode) {
     50     }
     51 
     52     public void backgrounded() {
     53     }
     54 
     55     public void storageWarning(long storageSpace) {
     56     }
     57 
     58     public void videoCaptureDoneEvent(String ref, long durationMsec, boolean front,
     59                                       float zoom, int width, int height, long size,
     60                                       String flashSetting, boolean gridLinesOn) {
     61     }
     62 
     63     public void photoCaptureDoneEvent(int mode, String fileRef, ExifInterface exifRef,
     64                                       boolean front, boolean isHDR, float zoom,
     65                                       String flashSetting, boolean gridLinesOn,
     66                                       Float timerSeconds, TouchCoordinate touch,
     67                                       Boolean volumeButtonShutter) {
     68     }
     69 
     70     public void cameraFailure(int cause, String info, int agentAction, int agentState) {
     71     }
     72 
     73     public void changeScreen(int newScreen, Integer interactionCause) {
     74     }
     75 
     76     public void controlUsed(int control) {
     77     }
     78 
     79     public void tapToFocus(TouchCoordinate touch, Float duration) {
     80     }
     81 
     82     public void reportMemoryConsumed(HashMap memoryData, String reportType) {
     83     }
     84 }
     85