1 package eu
.alefzero
.owncloud
.ui
.fragment
;
3 import eu
.alefzero
.owncloud
.PathLayout
;
4 import eu
.alefzero
.owncloud
.R
;
5 import android
.app
.Activity
;
6 import android
.os
.Bundle
;
7 import android
.support
.v4
.app
.Fragment
;
8 import android
.view
.LayoutInflater
;
9 import android
.view
.View
;
10 import android
.view
.ViewGroup
;
12 public class ActionBar
extends Fragment
{
15 public void onCreate(Bundle savedInstanceState
) {
16 super.onCreate(savedInstanceState
);
20 public View
onCreateView(LayoutInflater inflater
, ViewGroup container
,
21 Bundle savedInstanceState
) {
22 View v
= inflater
.inflate(R
.layout
.action_bar
, container
, false
);
27 public void onAttach(Activity activity
) {
28 super.onAttach(activity
);
31 public void setPath(String path
) {
32 if (getPathLayout() != null
)
33 getPathLayout().addPath(path
);
36 public String
getCurrentPath() {
37 if (getPathLayout() != null
)
38 return getPathLayout().getFullPath();
42 private PathLayout
getPathLayout() {
43 return (PathLayout
) getActivity().findViewById(R
.id
.pathLayout1
);