Pergunta

I Need To Use "getSystemService" In Custom Spinner, So Custom Spinner Extends

getSystemService Will Use To Copy Text To Clip Board is non-static

And I Am unable To Use It In Custom Spinner

Foi útil?

Solução

IMHO, a custom Spinner subclass has no business working with the clipboard. That is the responsibility of the fragment or activity that hosts the Spinner.

That being said, call getContext().getSystemService() from a method on a View.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top