Skip to content

Commit

Permalink
Fixed emulation bug and profile editing bug
Browse files Browse the repository at this point in the history
  • Loading branch information
WilliamLCobb committed Jan 3, 2016
1 parent 4210d40 commit 25c0fd7
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 25 deletions.
2 changes: 1 addition & 1 deletion desmume/src/MMU.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1928,7 +1928,7 @@ static INLINE u16 read_timer(int proc, int timerIndex)

//for unchained timers, we do not keep the timer up to date. its value will need to be calculated here
s32 diff = (s32)(nds.timerCycle[proc][timerIndex] - nds_timer);
assert(diff>=0);
//assert(diff>=0);
if(diff<0)
printf("NEW EMULOOP BAD NEWS PLEASE REPORT: TIME READ DIFF < 0 (%d) (%d) (%d)\n",diff,timerIndex,MMU.timerMODE[proc][timerIndex]);

Expand Down
4 changes: 1 addition & 3 deletions iNDS/AppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -258,10 +258,8 @@ - (NSString *)batteryDir
- (NSString *)documentsPath
{
if ([self isSystemApplication]) {
NSLog(@"You're System!");
return [[self rootDocumentsPath] stringByAppendingPathComponent:@"iNDS"];
} else {
NSLog(@"Not System");
return [self rootDocumentsPath];
}
}
Expand Down Expand Up @@ -320,7 +318,7 @@ - (void)moveFolderAtPath:(NSString *)oldDirectory toPath:(NSString *)newDirector
}

-(BOOL)isSystemApplication {
return [[[[NSBundle mainBundle] executablePath] pathComponents][0] isEqualToString:@"applications"];
return [[[[NSBundle mainBundle] executablePath] pathComponents][1] isEqualToString:@"db"];
}

- (void)applicationWillResignActive:(UIApplication *)application
Expand Down
38 changes: 19 additions & 19 deletions iNDS/MainStoryboard.storyboard
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@
<subviews>
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="Volume Button Bumpers" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="Kub-Od-1N5">
<rect key="frame" x="17" y="11" width="186" height="21"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="calibratedRGB"/>
<color key="highlightedColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
Expand Down Expand Up @@ -1073,7 +1073,7 @@
<tableViewSection id="XDo-J4-uHS">
<cells>
<tableViewCell clipsSubviews="YES" alpha="0.80000000000000004" contentMode="scaleToFill" selectionStyle="default" accessoryType="disclosureIndicator" indentationWidth="10" textLabel="7Nm-3Y-HQy" detailTextLabel="d6Z-Sh-06Y" style="IBUITableViewCellStyleValue1" id="qtg-s6-b8K">
<rect key="frame" x="0.0" y="44" width="260" height="44"/>
<rect key="frame" x="0.0" y="0.0" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" alpha="0.80000000000000004" contentMode="center" tableViewCell="qtg-s6-b8K" id="40a-1h-yQl">
<rect key="frame" x="0.0" y="0.0" width="227" height="43"/>
Expand All @@ -1100,7 +1100,7 @@
</connections>
</tableViewCell>
<tableViewCell clipsSubviews="YES" alpha="0.80000000000000004" contentMode="scaleToFill" selectionStyle="default" accessoryType="disclosureIndicator" indentationWidth="10" textLabel="2US-OK-06r" detailTextLabel="z6e-hj-9kP" style="IBUITableViewCellStyleValue1" id="qdH-LU-Kh9">
<rect key="frame" x="0.0" y="88" width="260" height="44"/>
<rect key="frame" x="0.0" y="44" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="qdH-LU-Kh9" id="iYh-6h-Gbr">
<rect key="frame" x="0.0" y="0.0" width="227" height="43"/>
Expand Down Expand Up @@ -1128,7 +1128,7 @@
</connections>
</tableViewCell>
<tableViewCell clipsSubviews="YES" alpha="0.80000000000000004" contentMode="scaleToFill" selectionStyle="default" accessoryType="disclosureIndicator" indentationWidth="10" editingAccessoryType="detailDisclosureButton" textLabel="P2c-hh-ouv" style="IBUITableViewCellStyleDefault" id="2tb-8c-vze">
<rect key="frame" x="0.0" y="132" width="260" height="44"/>
<rect key="frame" x="0.0" y="88" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="2tb-8c-vze" id="mIR-c6-hIm">
<rect key="frame" x="0.0" y="0.0" width="227" height="43"/>
Expand All @@ -1149,7 +1149,7 @@
</connections>
</tableViewCell>
<tableViewCell clipsSubviews="YES" alpha="0.80000000000000004" contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" textLabel="9Y1-Oj-gA3" style="IBUITableViewCellStyleDefault" id="dOE-Xx-DmR">
<rect key="frame" x="0.0" y="176" width="260" height="44"/>
<rect key="frame" x="0.0" y="132" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="dOE-Xx-DmR" id="nZT-Pz-8Bb">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand All @@ -1166,7 +1166,7 @@
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
</tableViewCell>
<tableViewCell clipsSubviews="YES" alpha="0.80000000000000004" contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" textLabel="OH5-aq-hT5" style="IBUITableViewCellStyleDefault" id="Byp-Sf-ZiE">
<rect key="frame" x="0.0" y="220" width="260" height="44"/>
<rect key="frame" x="0.0" y="176" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="Byp-Sf-ZiE" id="RUU-ei-nS5">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand Down Expand Up @@ -1196,7 +1196,7 @@
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
</tableViewCell>
<tableViewCell clipsSubviews="YES" alpha="0.80000000000000004" contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" indentationWidth="10" textLabel="QLj-V6-c8i" style="IBUITableViewCellStyleDefault" id="VHY-nL-9T6">
<rect key="frame" x="0.0" y="264" width="260" height="44"/>
<rect key="frame" x="0.0" y="220" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="VHY-nL-9T6" id="urG-vX-vso">
<rect key="frame" x="0.0" y="0.0" width="227" height="43"/>
Expand All @@ -1217,7 +1217,7 @@
</connections>
</tableViewCell>
<tableViewCell clipsSubviews="YES" alpha="0.80000000000000004" contentMode="scaleToFill" selectionStyle="default" accessoryType="disclosureIndicator" indentationWidth="10" textLabel="IrQ-Ld-BIK" style="IBUITableViewCellStyleDefault" id="12B-1B-5CL">
<rect key="frame" x="0.0" y="308" width="260" height="44"/>
<rect key="frame" x="0.0" y="264" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="12B-1B-5CL" id="S2T-4K-K33">
<rect key="frame" x="0.0" y="0.0" width="227" height="43"/>
Expand All @@ -1238,7 +1238,7 @@
</connections>
</tableViewCell>
<tableViewCell clipsSubviews="YES" alpha="0.80000000000000004" contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" indentationWidth="10" textLabel="lt9-GU-1uI" style="IBUITableViewCellStyleDefault" id="02l-Qp-XOh">
<rect key="frame" x="0.0" y="352" width="260" height="44"/>
<rect key="frame" x="0.0" y="308" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="02l-Qp-XOh" id="eAi-hm-iHm">
<rect key="frame" x="0.0" y="0.0" width="227" height="43"/>
Expand Down Expand Up @@ -1286,7 +1286,7 @@
<tableViewSection id="cPK-tV-LiU">
<cells>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" textLabel="x2E-FO-x01" style="IBUITableViewCellStyleDefault" id="3uA-hS-maE">
<rect key="frame" x="0.0" y="44" width="260" height="44"/>
<rect key="frame" x="0.0" y="0.0" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="3uA-hS-maE" id="LhI-ok-HkQ">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand All @@ -1303,7 +1303,7 @@
</tableViewCellContentView>
</tableViewCell>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" textLabel="uco-au-tPw" style="IBUITableViewCellStyleDefault" id="o4v-21-vZ8">
<rect key="frame" x="0.0" y="88" width="260" height="44"/>
<rect key="frame" x="0.0" y="44" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="o4v-21-vZ8" id="kMC-BV-cpY">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand All @@ -1320,7 +1320,7 @@
</tableViewCellContentView>
</tableViewCell>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" textLabel="Z1L-fs-zh3" style="IBUITableViewCellStyleDefault" id="4a4-5W-vOu">
<rect key="frame" x="0.0" y="132" width="260" height="44"/>
<rect key="frame" x="0.0" y="88" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="4a4-5W-vOu" id="Pio-KL-3kZ">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand All @@ -1337,7 +1337,7 @@
</tableViewCellContentView>
</tableViewCell>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" textLabel="CRW-Js-4qm" style="IBUITableViewCellStyleDefault" id="z8J-uI-n0O">
<rect key="frame" x="0.0" y="176" width="260" height="44"/>
<rect key="frame" x="0.0" y="132" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="z8J-uI-n0O" id="wZJ-UG-wEU">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand Down Expand Up @@ -1379,7 +1379,7 @@
<tableViewSection headerTitle="Name" footerTitle="Game ID: ABCD" id="42X-Aw-BBz">
<cells>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" id="XWQ-gT-69i">
<rect key="frame" x="0.0" y="94" width="260" height="44"/>
<rect key="frame" x="0.0" y="50" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="XWQ-gT-69i" id="RcL-GX-mDX">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand All @@ -1399,7 +1399,7 @@
<tableViewSection headerTitle="Code" id="ZGH-jB-Jsf">
<cells>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" rowHeight="202" id="bpK-c9-tc9">
<rect key="frame" x="0.0" y="205" width="260" height="202"/>
<rect key="frame" x="0.0" y="161" width="260" height="202"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="bpK-c9-tc9" id="SZS-Nf-12Q">
<rect key="frame" x="0.0" y="0.0" width="260" height="201"/>
Expand Down Expand Up @@ -1452,7 +1452,7 @@
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<prototypes>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" id="Fpz-3z-sVQ">
<rect key="frame" x="0.0" y="72" width="260" height="44"/>
<rect key="frame" x="0.0" y="28" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="Fpz-3z-sVQ" id="NLd-5T-m9Q">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand Down Expand Up @@ -1490,7 +1490,7 @@
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<prototypes>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" id="iNh-1y-Pge">
<rect key="frame" x="0.0" y="72" width="260" height="44"/>
<rect key="frame" x="0.0" y="28" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="iNh-1y-Pge" id="JXH-qC-G6S">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand Down Expand Up @@ -1519,7 +1519,7 @@
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<prototypes>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" id="N0C-ts-Wli">
<rect key="frame" x="0.0" y="72" width="260" height="44"/>
<rect key="frame" x="0.0" y="28" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="N0C-ts-Wli" id="vht-9v-M2u">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand Down Expand Up @@ -1548,7 +1548,7 @@
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<prototypes>
<tableViewCell contentMode="scaleToFill" selectionStyle="gray" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" reuseIdentifier="Cell" textLabel="PbD-9E-hsE" detailTextLabel="qaf-Bt-HzZ" style="IBUITableViewCellStyleSubtitle" id="DW4-7h-eOu">
<rect key="frame" x="0.0" y="72" width="260" height="44"/>
<rect key="frame" x="0.0" y="28" width="260" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="DW4-7h-eOu" id="V2S-Wl-wnh">
<rect key="frame" x="0.0" y="0.0" width="260" height="43"/>
Expand Down
Loading

0 comments on commit 25c0fd7

Please sign in to comment.