1 /* 2 * Copyright (C) 2016 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.dialer.app.legacybindings; 18 19 import android.app.Activity; 20 import android.support.annotation.NonNull; 21 import android.view.ViewGroup; 22 import com.android.dialer.app.calllog.CallLogAdapter; 23 import com.android.dialer.app.calllog.calllogcache.CallLogCache; 24 import com.android.dialer.app.contactinfo.ContactInfoCache; 25 import com.android.dialer.app.list.RegularSearchFragment; 26 import com.android.dialer.app.voicemail.VoicemailPlaybackPresenter; 27 import com.android.dialer.blocking.FilteredNumberAsyncQueryHandler; 28 29 /** Default implementation for dialer legacy bindings. */ 30 public class DialerLegacyBindingsStub implements DialerLegacyBindings { 31 32 @Override newCallLogAdapter( Activity activity, ViewGroup alertContainer, CallLogAdapter.CallFetcher callFetcher, CallLogCache callLogCache, ContactInfoCache contactInfoCache, VoicemailPlaybackPresenter voicemailPlaybackPresenter, @NonNull FilteredNumberAsyncQueryHandler filteredNumberAsyncQueryHandler, int activityType)33 public CallLogAdapter newCallLogAdapter( 34 Activity activity, 35 ViewGroup alertContainer, 36 CallLogAdapter.CallFetcher callFetcher, 37 CallLogCache callLogCache, 38 ContactInfoCache contactInfoCache, 39 VoicemailPlaybackPresenter voicemailPlaybackPresenter, 40 @NonNull FilteredNumberAsyncQueryHandler filteredNumberAsyncQueryHandler, 41 int activityType) { 42 return new CallLogAdapter( 43 activity, 44 alertContainer, 45 callFetcher, 46 callLogCache, 47 contactInfoCache, 48 voicemailPlaybackPresenter, 49 filteredNumberAsyncQueryHandler, 50 activityType); 51 } 52 53 @Override newRegularSearchFragment()54 public RegularSearchFragment newRegularSearchFragment() { 55 return new RegularSearchFragment(); 56 } 57 } 58