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 30 private static UsageStatistics sInstance; 31 32 public static UsageStatistics instance() { 33 if (sInstance == null) { 34 sInstance = new UsageStatistics(); 35 } 36 return sInstance; 37 } 38 39 public void initialize(Context context) { 40 } 41 42 public void mediaInteraction(String ref, int interactionType, int cause, float age) { 43 } 44 45 public void mediaView(String ref, long modifiedMillis, float zoom) { 46 } 47 48 public void foregrounded(int source, int mode) { 49 } 50 51 public void backgrounded() { 52 } 53 54 public void storageWarning(long storageSpace) { 55 } 56 57 public void videoCaptureDoneEvent(String ref, long durationMsec, boolean front, 58 float zoom, int width, int height, long size, 59 String flashSetting, boolean gridLinesOn) { 60 } 61 62 public void photoCaptureDoneEvent(int mode, String fileRef, ExifInterface exifRef, 63 boolean front, boolean isHDR, float zoom, 64 String flashSetting, boolean gridLinesOn, 65 Float timerSeconds, TouchCoordinate touch, 66 Boolean volumeButtonShutter) { 67 } 68 69 public void cameraFailure(int cause, String info) { 70 } 71 72 public void changeScreen(int newScreen, Integer interactionCause) { 73 } 74 75 public void controlUsed(int control) { 76 } 77 78 public void tapToFocus(TouchCoordinate touch, Float duration) { 79 } 80 81 public void reportMemoryConsumed(HashMap memoryData, String reportType) { 82 } 83 } 84