Bug ID: 111393
           Summary: Demuddle googleApiClient in CommunicationServiceWear
                    (findbugs Medium issue)
           Product: Impress Remote
           Version: unspecified
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Android app

We have a static GoogleApiClient living in CommunicationServiceWear. However
its actually treated as a member variable (i.e. should be specific to the
instance of CommunicationServiceWear that is being used).

Findbugs rightly complains - I'm planning to suppress that warning for now, but
we should somehow unmuddle this:

>Write to static field 
> from instance method 
> Bug type ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD (click for details)
> In class org.libreoffice.impressremote.communication.CommunicationServiceWear
> In method 
> org.libreoffice.impressremote.communication.CommunicationServiceWear.onCreate()
> Field 
> org.libreoffice.impressremote.communication.CommunicationServiceWear.googleApiClient
> At[line 61]

googleApiClient needs to (at this time) be static since its used by the
(static) presentationPaused()/presentationResumed() implementations. Those in
turn are called by SlideShowActivity. It might be simplest for
SlideShowActivity to simply have its own googleApiClient which it can use to
communicate the pausing/unpausing of the presentation, and then
CommunicationServiceWear can de-staticify its own googleApiClient.

You are receiving this mail because:
You are the assignee for the bug.
Libreoffice-bugs mailing list

Reply via email to