[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-edu-devel
Subject:    Re: [kde-edu-devel] Patch for flashKard
From:       cfaun <cfaun () rcn ! com>
Date:       2002-04-20 21:40:49
[Download RAW message or body]

Sorry. Here is the the (hopefully) correct patch.

On Saturday 20 April 2002 02:10 pm, Scott Wheeler wrote:
> Hi cfaun,
>
> This is mostly a patch to the automatically generated Makefiles and abo=
ut
> 5500 lines of it at that -- about three times the size of all of the
> sources for FlashKard.
>
> I tried to dig through and find the relevant parts, but eventually gave=
 up.
> Could you remake this for just the relevant files?  Also, since this is=
 now
> in KDE CVS, CVS patches are preferred.  i.e.
>
> cd ~/kde-cvs/kdeedu/flashkard/flashkard
> cvs diff <affected files -- foo.cpp foo.h> > ~/flashkard-patch.diff
>
> You can just do it for the directory -- something just like "cvs diff",=
 but
> please do a "make distclean" before you do that to clear out the
> automatically generated files.  In other words if this ends up being mo=
re
> than 100 lines or so, you've probably done something wrong.
>
> -Scott
>
> On Saturday 20 April 2002 12:21 pm, cfaun wrote:
> > I just made a patch with some minor bugfixes (fixes progress bar and
> > makes it so if you are saving a file and don't put the .kvml extensio=
n
> > on, it puts it on for you). It is attached (I hope I did it right...)
>
> _______________________________________________
> kde-edu-devel mailing list
> kde-edu-devel@mail.kde.org
> http://mail.kde.org/mailman/listinfo/kde-edu-devel

["patch.diff" (text/x-diff)]

Index: flashkard//flashkard.kdevprj
===================================================================
RCS file: /home/kde/kdeedu/flashkard/flashkard.kdevprj,v
retrieving revision 1.1
diff -u -3 -p -r1.1 flashkard.kdevprj
--- flashkard//flashkard.kdevprj	11 Apr 2002 07:29:42 -0000	1.1
+++ flashkard//flashkard.kdevprj	20 Apr 2002 19:12:34 -0000
@@ -26,7 +26,7 @@ ldadd=\s$(LIB_KFILE) $(LIB_KDEUI) $(LIB_
 ldflags=\s\s
 
 [General]
-AMChanged=true
+AMChanged=false
 author=Scott Wheeler
 configure_args=\s--build=i386-linux --host=i386-linux --target=i386-linux\s
 email=scott@slackorama.net
Index: flashkard//flashkard.kdevses
===================================================================
RCS file: /home/kde/kdeedu/flashkard/flashkard.kdevses,v
retrieving revision 1.1
diff -u -3 -p -r1.1 flashkard.kdevses
--- flashkard//flashkard.kdevses	11 Apr 2002 07:29:42 -0000	1.1
+++ flashkard//flashkard.kdevses	20 Apr 2002 19:12:35 -0000
@@ -3,5 +3,33 @@
 <KDevPrjSession>
  <LastCompileConfig>(Default)</LastCompileConfig>
  <Mainframe MaximizeMode="1" />
- <DocsAndViews NumberOfDocuments="0" />
+ <DocsAndViews NumberOfDocuments="9" >
+  <Doc0 CursorPosLine="25" Type="KWriteDoc" NumberOfViews="1" CursorPosCol="0" \
FileName="/home/cfaun/kdeedu/flashkard/flashkard/datawidget.h" > +   <View0 Top="24" \
Width="400" Attach="1" Height="300" Left="3" Focus="0" Type="KWriteView" \
MinMaxMode="0" /> +  </Doc0>
+  <Doc1 CursorPosLine="38" Type="KWriteDoc" NumberOfViews="1" CursorPosCol="0" \
FileName="/home/cfaun/kdeedu/flashkard/flashkard/card.h" > +   <View0 Top="46" \
Width="758" Attach="1" Height="410" Left="25" Focus="0" Type="KWriteView" \
MinMaxMode="0" /> +  </Doc1>
+  <Doc2 CursorPosLine="25" Type="KWriteDoc" NumberOfViews="1" CursorPosCol="0" \
FileName="/home/cfaun/kdeedu/flashkard/flashkard/flashcardswidget.h" > +   <View0 \
Top="90" Width="758" Attach="1" Height="410" Left="69" Focus="0" Type="KWriteView" \
MinMaxMode="0" /> +  </Doc2>
+  <Doc3 CursorPosLine="34" Type="KWriteDoc" NumberOfViews="1" CursorPosCol="0" \
FileName="/home/cfaun/kdeedu/flashkard/flashkard/flashkard.h" > +   <View0 Top="112" \
Width="758" Attach="1" Height="410" Left="91" Focus="0" Type="KWriteView" \
MinMaxMode="0" /> +  </Doc3>
+  <Doc4 CursorPosLine="28" Type="KWriteDoc" NumberOfViews="1" CursorPosCol="0" \
FileName="/home/cfaun/kdeedu/flashkard/flashkard/guesswidget.h" > +   <View0 \
Top="134" Width="758" Attach="1" Height="410" Left="113" Focus="0" Type="KWriteView" \
MinMaxMode="0" /> +  </Doc4>
+  <Doc5 CursorPosLine="66" Type="KWriteDoc" NumberOfViews="1" CursorPosCol="62" \
FileName="/home/cfaun/kdeedu/flashkard/flashkard/quizwidget.h" > +   <View0 Top="156" \
Width="758" Attach="1" Height="410" Left="135" Focus="0" Type="KWriteView" \
MinMaxMode="0" /> +  </Doc5>
+  <Doc6 CursorPosLine="116" Type="KWriteDoc" NumberOfViews="1" CursorPosCol="102" \
FileName="/home/cfaun/kdeedu/flashkard/flashkard/quizwidget.cpp" > +   <View0 \
Top="178" Width="758" Attach="1" Height="410" Left="157" Focus="0" Type="KWriteView" \
MinMaxMode="0" /> +  </Doc6>
+  <Doc7 CursorPosLine="239" Type="KWriteDoc" NumberOfViews="1" CursorPosCol="24" \
FileName="/home/cfaun/kdeedu/flashkard/flashkard/flashkard.cpp" > +   <View0 \
Top="176" Width="764" Attach="1" Height="437" Left="176" Focus="1" Type="KWriteView" \
MinMaxMode="2" /> +  </Doc7>
+  <Doc8 Type="CDocBrowser" NumberOfViews="1" \
FileName="/usr/local/qt/doc/html/qstring.html#append" > +   <View Top="68" \
Width="124" Attach="1" Height="115" Left="47" Focus="0" Type="KHTMLView" \
MinMaxMode="0" /> +  </Doc8>
+ </DocsAndViews>
 </KDevPrjSession>
Index: flashkard//flashkard/flashkard.cpp
===================================================================
RCS file: /home/kde/kdeedu/flashkard/flashkard/flashkard.cpp,v
retrieving revision 1.7
diff -u -3 -p -r1.7 flashkard.cpp
--- flashkard//flashkard/flashkard.cpp	20 Apr 2002 03:33:08 -0000	1.7
+++ flashkard//flashkard/flashkard.cpp	20 Apr 2002 19:12:36 -0000
@@ -236,6 +236,8 @@ void FlashKard::fileSave()
 void FlashKard::fileSaveAs()
 {
   fileName = KFileDialog::getSaveFileName(QString::null, fileMask, this, \
QString::null); +  if(fileName.find(".kvml") == -1)
+    fileName += ".kvml";
   if(!fileName.isEmpty())
     fileSave();
 }
Index: flashkard//flashkard/quizwidget.cpp
===================================================================
RCS file: /home/kde/kdeedu/flashkard/flashkard/quizwidget.cpp,v
retrieving revision 1.5
diff -u -3 -p -r1.5 quizwidget.cpp
--- flashkard//flashkard/quizwidget.cpp	20 Apr 2002 03:33:08 -0000	1.5
+++ flashkard//flashkard/quizwidget.cpp	20 Apr 2002 19:12:36 -0000
@@ -97,6 +97,7 @@ Card QuizWidget::getCard(bool random)
 {
   if(!completeCardList->isEmpty()) {
     if(remainingCardList.isEmpty()) {
+      progressBar->setValue(100);
       KMessageBox::information( this, i18n("Restarting the deck."), \
i18n("FlashKard"));  remainingCardList = *completeCardList;
     }
@@ -113,7 +114,7 @@ Card QuizWidget::getCard(bool random)
     showCard(card);
 
     if(completeCardList->count() > 0)
-      progressBar->setValue(int(100.0 * (1.0 - float(remainingCardList.count()) / \
float(completeCardList->count() - 1)) + .5)); +      progressBar->setValue(int(100.0 \
* (float((completeCardList->count()-1)-remainingCardList.count()) / \
float(completeCardList->count()))));  
     return(card);
   }


_______________________________________________
kde-edu-devel mailing list
kde-edu-devel@mail.kde.org
http://mail.kde.org/mailman/listinfo/kde-edu-devel

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic