File tree Expand file tree Collapse file tree 4 files changed +19
-3
lines changed
org.gitools.ui.app/src/main/java/org/gitools/ui/app/welcome
org.gitools.ui.core/src/main/java/org/gitools/ui/core Expand file tree Collapse file tree 4 files changed +19
-3
lines changed Original file line number Diff line number Diff line change @@ -143,15 +143,27 @@ public void run(IProgressMonitor monitor) {
143143 }
144144 });
145145
146+ // Track event
147+ String baseName = FilenameUtils .getBaseName (href );
148+ Application .get ().trackEvent ("datasets" , "save" , baseName );
149+
146150 }
147151
148152
149153 }
150154
151155 @ Override
152156 protected void performLoad (String href ) {
157+
153158 CommandLoadFile loadFile = new CommandLoadFile (href );
159+
160+ // Execute
154161 JobThread .execute (Application .get (), loadFile );
162+
163+ // Track event
164+ String baseName = FilenameUtils .getBaseName (href );
165+ Application .get ().trackEvent ("datasets" , "load" , baseName );
166+
155167 }
156168
157169 @ Override
Original file line number Diff line number Diff line change 2626import com .alee .managers .notification .NotificationManager ;
2727import com .alee .managers .notification .NotificationOption ;
2828import com .alee .managers .notification .WebNotificationPopup ;
29+ import com .brsanthu .googleanalytics .AwtRequestParameterDiscoverer ;
2930import com .brsanthu .googleanalytics .EventHit ;
3031import com .brsanthu .googleanalytics .ExceptionHit ;
3132import com .brsanthu .googleanalytics .GoogleAnalytics ;
33+ import com .brsanthu .googleanalytics .GoogleAnalyticsConfig ;
3234import org .gitools .resource .SemanticVersion ;
3335import org .gitools .ui .core .components .StatusBar ;
3436import org .gitools .ui .core .components .editor .AbstractEditor ;
@@ -72,6 +74,9 @@ public class Application extends JFrame implements IApplicationTracking {
7274 }
7375
7476 appVersion = new SemanticVersion (settings .getProperty ("version" ));
77+
78+ GoogleAnalyticsConfig config = new GoogleAnalyticsConfig ();
79+ config .setRequestParameterDiscoverer (new AwtRequestParameterDiscoverer ());
7580 analytics = new GoogleAnalytics (appTracking , appName , appVersion .toString ());
7681 analytics .getDefaultRequest ().clientId (Settings .get ().getUuid ());
7782 }
Original file line number Diff line number Diff line change @@ -65,13 +65,12 @@ public AbstractAction(String name) {
6565 protected void track (String category , String label ) {
6666
6767 if (actionName == null ) {
68- getClass ().getSimpleName ().replace ("Action" , "" );
68+ actionName = getClass ().getSimpleName ().replace ("Action" , "" );
6969 }
7070
7171 Application .get ().trackEvent (category , actionName , label );
7272 }
7373
74-
7574 public void setParentWindow (Window parentWindow ) {
7675 this .parentWindow = parentWindow ;
7776 }
Original file line number Diff line number Diff line change 237237 <dependency >
238238 <groupId >com.brsanthu</groupId >
239239 <artifactId >google-analytics-java</artifactId >
240- <version >1.0.4 </version >
240+ <version >1.1.1 </version >
241241 </dependency >
242242
243243 <dependency >
You can’t perform that action at this time.
0 commit comments