Skip to content

Commit

Permalink
added back some indentation levels
Browse files Browse the repository at this point in the history
  • Loading branch information
yujitach committed Nov 7, 2021
1 parent d2377c8 commit 385c074
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
5 changes: 5 additions & 0 deletions MenuExtras/MenuMeterCPU/MenuMeterCPUExtra.m
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ - (instancetype)init {
keyEquivalent:@""];
[menuItem setEnabled:NO];
menuItem = [extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];

// Add task title and blanks for task display
Expand All @@ -154,6 +155,7 @@ - (instancetype)init {
keyEquivalent:@""];
[menuItem setEnabled:NO];
menuItem = [extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];

// Add load title and blanks for load display
Expand All @@ -162,13 +164,15 @@ - (instancetype)init {
keyEquivalent:@""];
[menuItem setEnabled:NO];
menuItem = [extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];

menuItem = [extraMenu addItemWithTitle:[bundle localizedStringForKey:kCPUPowerLimitStatusTitle value:nil table:nil]
action:nil
keyEquivalent:@""];
[menuItem setEnabled:NO];
menuItem = [extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];

// Add top kCPUrocessCountMax most CPU intensive processes
Expand All @@ -180,6 +184,7 @@ - (instancetype)init {
// as this list is "static" unfortunately we need all of the kCPUrocessCountMax menu items and hide/show later the un-wanted/wanted ones
for (NSInteger ndx = 0; ndx < kCPUrocessCountMax; ++ndx) {
menuItem = [extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];
}

Expand Down
14 changes: 13 additions & 1 deletion MenuExtras/MenuMeterMem/MenuMeterMemExtra.m
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ - (instancetype)init {
keyEquivalent:@""];
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];

// Add memory page stats title and placeholders
Expand All @@ -129,10 +130,13 @@ - (instancetype)init {
keyEquivalent:@""];
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];

// Add VM stats menu items and placeholders
Expand All @@ -141,10 +145,13 @@ - (instancetype)init {
keyEquivalent:@""];
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];

// add items for memory pressure
Expand All @@ -153,6 +160,7 @@ - (instancetype)init {
keyEquivalent:@""];
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];

// Swap file stats menu item and placeholders
Expand All @@ -161,10 +169,13 @@ - (instancetype)init {
keyEquivalent:@""];
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];
menuItem = (NSMenuItem *)[extraMenu addItemWithTitle:@"" action:nil keyEquivalent:@""];
menuItem.indentationLevel=1;
[menuItem setEnabled:NO];
[extraMenu addItem:[NSMenuItem separatorItem]];
[self addStandardMenuEntriesTo:extraMenu];
Expand All @@ -178,7 +189,8 @@ - (instancetype)init {
[tempFormat setFormat:[NSString stringWithFormat:@"#,##0.0%@", [localizedStrings objectForKey:kMBLabel]]];
// Go through an archive/unarchive cycle to work around a bug on pre-10.2.2 systems
// see http://cocoa.mamasam.com/COCOADEV/2001/12/2/21029.php
memFloatMBFormatter = [NSUnarchiver unarchiveObjectWithData:[NSArchiver archivedDataWithRootObject:tempFormat]];
// memFloatMBFormatter = [NSUnarchiver unarchiveObjectWithData:[NSArchiver archivedDataWithRootObject:tempFormat]];
memFloatMBFormatter = tempFormat;
[tempFormat setFormat:[NSString stringWithFormat:@"#,##0%@", [localizedStrings objectForKey:kMBLabel]]];
memIntMBFormatter = [NSUnarchiver unarchiveObjectWithData:[NSArchiver archivedDataWithRootObject:tempFormat]];
[tempFormat setFormat:@"#,##0"];
Expand Down

0 comments on commit 385c074

Please sign in to comment.