Use NSUInteger in BSSourceView.{h,m}
authorRobert Sesek <rsesek@bluestatic.org>
Tue, 11 Jan 2011 02:45:03 +0000 (21:45 -0500)
committerRobert Sesek <rsesek@bluestatic.org>
Tue, 11 Jan 2011 02:45:03 +0000 (21:45 -0500)
Source/BSSourceView.h
Source/BSSourceView.m
Source/BreakpointController.m

index 811f834ffc703fc1f2ee86eb6dbc9c3d1b5046ba..4f92f10c3ef4137d01b37ba82748c95481717527 100644 (file)
@@ -27,7 +27,7 @@
   NSScrollView* scrollView;
   
   NSString* file;
-  int markedLine;
+  NSUInteger markedLine;
   
   id<BSSourceViewDelegate> delegate;
 }
 @property(readwrite, assign) BSSourceViewTextView* textView;
 @property(readwrite, assign) NSScrollView* scrollView;
 @property(readwrite, nonatomic, assign) NSString* file;
-@property(readwrite, assign) int markedLine;
+@property(readwrite, assign) NSUInteger markedLine;
 @property(readwrite, assign) id delegate;
 
 - (void)setFile:(NSString*)f;
 - (void)setString:(NSString*)source asFile:(NSString*)path;
-- (void)scrollToLine:(int)line;
+- (void)scrollToLine:(NSUInteger)line;
 
 @end
 
@@ -51,7 +51,7 @@
 @optional
 
 // Notifies the delegate that the gutter was clicked at a certain line.
-- (void)gutterClickedAtLine:(int)line forFile:(NSString*)file;
+- (void)gutterClickedAtLine:(NSUInteger)line forFile:(NSString*)file;
 
 // Whether to accept a file drop.
 - (BOOL)sourceView:(BSSourceView*)sv acceptsDropOfFile:(NSString*)fileName;
index 55481eb0eca721226e9c2a0b1d80ff51a5e488f8..209f9722cda0a55d7579e5d345eafacd4953bc37 100644 (file)
 /**
  * Tells the text view to scroll to a certain line
  */
-- (void)scrollToLine:(int)line
+- (void)scrollToLine:(NSUInteger)line
 {
   if ([[textView textStorage] length] == 0)
     return;
   
   // go through the document until we find the NSRange for the line we want
   int rangeIndex = 0;
-  for (int i = 0; i < line; i++)
+  for (NSUInteger i = 0; i < line; i++)
   {
     rangeIndex = NSMaxRange([[textView string] lineRangeForRange:NSMakeRange(rangeIndex, 0)]);
   }
  */
 - (void)setupViews
 {
-  int gutterWidth = 30;
+  NSUInteger gutterWidth = 30;
   
   // setup the line number view
   NSRect numberFrame = [self bounds];
index f50a63c957af6110d1264869afb1b8ec9c092d85..9645b4327d2a7ee037c70047e46175e22bcadb6f 100644 (file)
@@ -94,7 +94,7 @@
 /**
  * The gutter was clicked, which indicates that a breakpoint needs to be changed
  */
-- (void)gutterClickedAtLine:(int)line forFile:(NSString*)file
+- (void)gutterClickedAtLine:(NSUInteger)line forFile:(NSString*)file
 {
   if ([manager hasBreakpointAt:line inFile:file])
   {