Thiago
Thiago

Reputation: 13302

How to call requestWindowFeature inside Fragment

I want to call :

requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);

but the code below does not work:

@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
        Bundle savedInstanceState) {
    requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
    View rootView = inflater.inflate(R.layout.fragment_login, container, false);

     return rootView;
    }//end onCreateView

can someone give a hand, pls. thanks

Upvotes: 0

Views: 3408

Answers (1)

M D
M D

Reputation: 47817

try this in Fragment

getActivity().requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);

Upvotes: 4

Related Questions