diff --git a/AppDelegate.h b/AppDelegate.h
index 05f060d..6e06e93 100755
--- a/AppDelegate.h
+++ b/AppDelegate.h
@@ -141,11 +141,6 @@
//remote XPC interface
@property (nonatomic, retain) NSXPCConnection* xpcConnection;
-//action for 'refresh' button
-// ->query OS to refresh/reload all tasks
-- (IBAction)refreshTasks:(id)sender;
-
-
/* METHODS */
@@ -162,6 +157,9 @@
// ->provide mouse over effects
-(void)initTrackingAreas;
+//action for 'refresh' button
+// ->query OS to refresh/reload all tasks
+-(IBAction)refreshTasks:(id)sender;
//callback when user has updated prefs
diff --git a/AppDelegate.m b/AppDelegate.m
index 174f500..3fc2ed5 100755
--- a/AppDelegate.m
+++ b/AppDelegate.m
@@ -421,7 +421,6 @@ bail:
//get row
row = [self.taskTableController.filteredItems indexOfObject:item];
}
-
}
//reload item
// ->tree view, so no need to worry about filtering
@@ -1300,6 +1299,14 @@ bail:
//remove all filtered items
[self.bottomViewController.filteredItems removeAllObjects];
+ //for currently selected tasks
+ // ->check if its still alive
+ if(nil != self.currentTask)
+ {
+ //helper method that takes care of all check/handling dead tasks :)
+ [self.taskTableController handleRowSelection];
+ }
+
//when no current task
// ->set to first task in sorted tasks
if(nil == self.currentTask)
@@ -1578,9 +1585,6 @@ bail:
//unselect current task
self.currentTask = nil;
- //select top row
- [self.taskTableController.itemView selectRowIndexes:[NSIndexSet indexSetWithIndex:0] byExtendingSelection:NO];
-
//TODO: don't reset filtered items?
// ...will require some smart filtering :/
@@ -1592,10 +1596,16 @@ bail:
//reset filter box
self.filterTasksBox.stringValue = @"";
-
+
+ //reset segment (bottom pane) back to dylibs
+ self.bottomPaneBtn.selectedSegment = DYLIBS_VIEW;
+
//scroll to top
[self.taskTableController scrollToTop];
-
+
+ //select top row
+ [self.taskTableController.itemView selectRowIndexes:[NSIndexSet indexSetWithIndex:0] byExtendingSelection:NO];
+
//get tasks
// ->background thread will enum tasks, update table, etc
[self exploreTasks];
diff --git a/RequestRootWindowController.m b/RequestRootWindowController.m
index f199215..45ab92e 100644
--- a/RequestRootWindowController.m
+++ b/RequestRootWindowController.m
@@ -155,7 +155,7 @@
//2nd arg: permissions
// ->4 at front is setuid
//TODO: make 4755 before deploy (for testing, 777 makes XCOde be able to del it during build!)
- installArgs[1] = "4777";
+ installArgs[1] = "4755";
//3rd arg: XPC service
installArgs[2] = [xpcService UTF8String];
@@ -224,7 +224,6 @@ bail:
//invoked when user clicks 'help' button
// ->open product's page w/ anchor to help
-//TODO: make sure taskexplorer.html#help has help!
-(IBAction)help:(id)sender
{
//open URL
diff --git a/TaskExplorer-Info.plist b/TaskExplorer-Info.plist
index 3ed331a..73ed46b 100755
--- a/TaskExplorer-Info.plist
+++ b/TaskExplorer-Info.plist
@@ -17,11 +17,11 @@
CFBundlePackageType
APPL
CFBundleShortVersionString
- 1.0.0
+ 0.9.1
CFBundleSignature
????
CFBundleVersion
- 1.0.0
+ 0.9.1
LSMinimumSystemVersion
${MACOSX_DEPLOYMENT_TARGET}
NSHumanReadableCopyright
diff --git a/TaskExplorer.xcodeproj/xcuserdata/patrick.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/TaskExplorer.xcodeproj/xcuserdata/patrick.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
index 80041c9..a58092b 100644
--- a/TaskExplorer.xcodeproj/xcuserdata/patrick.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
+++ b/TaskExplorer.xcodeproj/xcuserdata/patrick.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
@@ -254,31 +254,15 @@
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "AppDelegate.m"
- timestampString = "460150711.336469"
+ timestampString = "460247716.301871"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
- startingLineNumber = "1691"
- endingLineNumber = "1691"
+ startingLineNumber = "1619"
+ endingLineNumber = "1619"
landmarkName = "-constrainView:subView:"
landmarkType = "5">
-
-
-
-
@@ -302,11 +286,11 @@
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "remoteTaskService/remoteTaskService.m"
- timestampString = "460135710.183022"
+ timestampString = "460246314.23885"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
- startingLineNumber = "736"
- endingLineNumber = "736"
+ startingLineNumber = "754"
+ endingLineNumber = "754"
landmarkName = "socketState2String()"
landmarkType = "7">
@@ -318,14 +302,94 @@
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "remoteTaskService/remoteTaskService.m"
- timestampString = "460098075.239358"
+ timestampString = "460246314.23885"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
- startingLineNumber = "521"
- endingLineNumber = "521"
+ startingLineNumber = "539"
+ endingLineNumber = "539"
landmarkName = "-enumerateNetwork:withReply:"
landmarkType = "5">
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/TaskTableController.m b/TaskTableController.m
index c16f9f5..cb54279 100644
--- a/TaskTableController.m
+++ b/TaskTableController.m
@@ -45,7 +45,7 @@
if(YES != self.didInit)
{
//init selected row
- self.selectedRow = -1;
+ self.selectedRow = 0;
//alloc array for filtered items
filteredItems = [NSMutableArray array];
@@ -61,25 +61,9 @@
self.didInit = YES;
}
-
+ return;
}
-
-/*
-//invoked automatically while nib is loaded
-// ->note: outlets are nil here...
--(id)init
-{
- self = [super init];
- if(nil != self)
- {
- self.selectedRow = -1;
- }
-
- return self;
-}
-*/
-
//table delegate
// ->return number of rows, which is just number of items in the currently selected plugin
-(NSInteger)numberOfRowsInTableView:(NSTableView *)tableView
@@ -464,7 +448,18 @@ bail:
if(nil != selectedTask)
{
//get task's index
- taskIndex = [tasks indexOfKey:selectedTask.pid];
+ // ->flat view, can do a straight lookup
+ if(YES != [self.itemView isKindOfClass:[NSOutlineView class]])
+ {
+ //get index
+ taskIndex = [tasks indexOfKey:selectedTask.pid];
+ }
+ //get task's index
+ // ->outline view, use 'rowForItem' method
+ else
+ {
+ taskIndex = [(NSOutlineView*)self.itemView rowForItem:selectedTask];
+ }
//(re)select task's row
// ->but only if task still exists (e.g. didn't exit)
@@ -907,7 +902,7 @@ bail:
goto bail;
}
- //get row that's about to be selected
+ //get view that's about to be selected
selectedView = [self.itemView viewAtColumn:0 row:newlySelectedRow makeIfNecessary:YES];
//extract task
@@ -923,8 +918,8 @@ bail:
//draw
[selectedView setNeedsDisplay:YES];
- //make hide it after 1/4th second
- dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(.25 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
+ //make hide it after .33 second
+ dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(.33 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
//reset color
((kkRowCell*)selectedView).color = nil;
@@ -974,7 +969,7 @@ bail:
}
//ignore if row selection and task didn't change
- if( ([self.itemView selectedRow] == self.selectedRow) &&
+ if( (newlySelectedRow == self.selectedRow) &&
(((AppDelegate*)[[NSApplication sharedApplication] delegate]).currentTask == task) )
{
//ignore
diff --git a/VirusTotal.m b/VirusTotal.m
index 614f443..454db19 100644
--- a/VirusTotal.m
+++ b/VirusTotal.m
@@ -154,7 +154,7 @@
for(Binary* item in vtItems)
{
//skip items with blank hashes
- // ->TODO not sure why this would happen
+ // ->not sure why this would happen...
if(nil == item.hashes[KEY_HASH_SHA1])
{
//skip
diff --git a/en.lproj/MainMenu.xib b/en.lproj/MainMenu.xib
index 8433ff0..66e5f38 100755
--- a/en.lproj/MainMenu.xib
+++ b/en.lproj/MainMenu.xib
@@ -123,7 +123,7 @@
-
+
diff --git a/remoteTaskService/remoteTaskService.m b/remoteTaskService/remoteTaskService.m
index 2c03c24..8a96c42 100644
--- a/remoteTaskService/remoteTaskService.m
+++ b/remoteTaskService/remoteTaskService.m
@@ -314,7 +314,11 @@ bail:
//file info dictionary
NSMutableDictionary* fileInfo = nil;
- //files
+ //just file paths
+ // ->helps detect/ignore dups
+ NSMutableArray* filePaths = nil;
+
+ //unique files
NSMutableArray* files = nil;
//init task
@@ -323,7 +327,10 @@ bail:
//init pipe
pipe = [NSPipe pipe];
- //init array for files
+ //init array for file paths
+ filePaths = [NSMutableArray array];
+
+ //init array for unqiue files
files = [NSMutableArray array];
//set task's stdout to pipe
@@ -396,6 +403,13 @@ bail:
continue;
}
+ //also avoid duplicates
+ if(YES == [filePaths containsObject:filePath])
+ {
+ //skip
+ continue;
+ }
+
//alloc info dictionary
fileInfo = [NSMutableDictionary dictionary];
@@ -404,6 +418,10 @@ bail:
//save
[files addObject:fileInfo];
+
+ //add to list of paths
+ // ->prevents dups
+ [filePaths addObject:filePath];
}
//bail