[Thread Prev][Thread Next][Thread Index]
[PilotMgr] conduit for pedits Memo32DB
- To: pilotmgr@xxxxxxxxxxxxxxxxxxxx
- Subject: [PilotMgr] conduit for pedits Memo32DB
- From: Bodo Bellut <bodo@xxxxxxxxxx>
- Date: Thu, 19 Oct 2000 03:03:51 +0200
- Sender: owner-pilotmgr@xxxxxxxxxxxxxxxxxxxx
Hi,
I tried modifying SyncMemo (1.7) to work with pedits[1] Memo32DB instead of
the original MemoDB (diff included below). This should be trivial, as both
databases have the same structure, only the Memo32DB-records can be up to 32kB
big.
But when I try to use this, I get
10/19/2000 2:16:04 Synchronizing using the SyncMemo32 conduit
10/19/2000 2:16:04 SyncMemo32 did not complete cleanly.
Error Can't use an undefined value as an ARRAY reference
at SyncMemo32.pm line 466.
Trying to continue.
Am I missing something?
cu, Bodo
[1] http://www.PaulComputing.com/
--- SyncMemo.pm Wed Mar 10 00:58:32 1999
+++ SyncMemo32.pm Thu Oct 19 02:04:08 2000
@@ -24,10 +24,13 @@
# Alan.Harder@xxxxxxx
# version 1.7, 2/99
#
+# Modified for pedit's Memo32DB by Bodo Bellut, bodo@xxxxxxxxxx
+# 10/19/2000
+#
# Patch to use Shell.pm module instead of backtick(`) shell calls in v1.7
# submitted by Jeff Dairiki <dairiki@xxxxxxxxxxx>.
#
-package SyncMemo;
+package SyncMemo32;
use Tk;
use TkUtils;
@@ -58,17 +61,17 @@
sub conduitInit
{
- $RCFILE = "SyncMemo/SyncMemo.prefs";
- $DBFILE = $PREFS->{"DBFILE"} = "SyncMemo/SyncMemo.db";
+ $RCFILE = "SyncMemo32/SyncMemo32.prefs";
+ $DBFILE = $PREFS->{"DBFILE"} = "SyncMemo32/SyncMemo32.db";
&loadPrefs;
- $PREFS->{"gHomeDirectory"} = "$ENV{HOME}/.pilotmgr/SyncMemo"
+ $PREFS->{"gHomeDirectory"} = "$ENV{HOME}/.pilotmgr/SyncMemo32"
unless (defined($PREFS->{"gHomeDirectory"}));
$PREFS->{"gOnlyAscii"} = 1
unless (defined($PREFS->{"gOnlyAscii"}));
$PREFS->{"OnlyFilesToPilot"} = 0
unless (defined($PREFS->{"OnlyFilesToPilot"}));
- $PREFS->{"gMemoUpdater"} = "$ENV{HOME}/.pilotmgr/SyncMemo/update"
+ $PREFS->{"gMemoUpdater"} = "$ENV{HOME}/.pilotmgr/SyncMemo32/update"
unless (defined($PREFS->{"gMemoUpdater"}));
$PREFS->{"gUseUpdater"} = 0
unless (defined($PREFS->{"gUseUpdater"}));
@@ -107,8 +110,8 @@
{
return { "database" =>
{
- "name" => "MemoDB",
- "creator" => "memo",
+ "name" => "Memo32DB",
+ "creator" => "pn32",
"type" => "DATA",
"flags" => 0,
"version" => 0,
@@ -125,7 +128,7 @@
unless (defined($gConfigDialog))
{
- $gConfigDialog = $wm->Toplevel(-title => "Configuring SyncMemo");
+ $gConfigDialog = $wm->Toplevel(-title => "Configuring SyncMemo32");
$gConfigDialog->transient($wm);
$gYesNoDialog = $wm->Dialog(-title => "Do Something",
@@ -138,30 +141,30 @@
-overanchor => 'c', -popanchor => 'c');
PilotMgr::setColors($gYesNoDialog);
- $gInfoDialog = $wm->Toplevel(-title => "SyncMemo");
+ $gInfoDialog = $wm->Toplevel(-title => "SyncMemo32");
$gInfoDialog->transient($wm);
$gInfoDialog->withdraw;
$frame = $gInfoDialog->Frame;
($obj) = TkUtils::Text($frame, "Sync Type Info");
$obj->insert('end',
- "Sometimes SyncMemo will popup a dialog asking whether " .
+ "Sometimes SyncMemo32 will popup a dialog asking whether " .
"a full or fast sync should be performed. The purpose of " .
"this dialog is to make sure all memo changes get noticed " .
"during the hotsync. There are two cases this might not " .
- "happen:\n 1. You have restored a backed up MemoDB file- any " .
+ "happen:\n 1. You have restored a backed up Memo32DB file- any " .
"and all memos may now be totally different, so a full sync " .
"is in order!\n 2. You have synced to another machine- when " .
"you do this the memos you had changed will be updated to " .
- "THAT machine, and then cleared so that when SyncMemo does " .
+ "THAT machine, and then cleared so that when SyncMemo32 does " .
"its next sync it doesn't know the memo has changed. The " .
"only way to get all the changes is to do a full sync " .
"(load ALL the memos and look at them to see if they have " .
"changed).\nIf you find that you see this dialog a lot and " .
"always give the same answer you can use the Default Sync " .
- "Type option in the SyncMemo configuration dialog to specify ".
+ "Type option in the SyncMemo32 configuration dialog to specify ".
"a default answer. HOWEVER, if you choose Fast Sync as your ".
"default YOU must be aware of when the above conditions " .
- "occur and manually select Reset SyncMemo from the config " .
+ "occur and manually select Reset SyncMemo32 from the config " .
"dialog to force a full sync.");
$obj->configure(-height => 20, -state => 'disabled');
$obj->pack(-expand => 1, -fill => 'both');
@@ -171,11 +174,11 @@
PilotMgr::setColors($gInfoDialog);
$frame = $gConfigDialog->Frame(-relief => "ridge", -bd => 4);
- $obj = TkUtils::Label($frame, "SyncMemo Settings");
+ $obj = TkUtils::Label($frame, "SyncMemo32 Settings");
$obj->pack(-anchor => "c");
$subfr = $frame->Frame;
- $obj = $subfr->Label(-text => "Memo directory: ");
+ $obj = $subfr->Label(-text => "Memo32 directory: ");
$obj->pack(-side => "left", -anchor => "nw", -fill => "x");
$obj = $subfr->Entry(-textvariable => \$PREFS->{"gHomeDirectory"},
@@ -301,7 +304,7 @@
$obj->pack(-anchor => "center");
$obj = TkUtils::Label($frame,
"These options allow special actions to be performed on your " .
- "next hotsync.\nA Reset will cause SyncMemo to reexamine ALL " .
+ "next hotsync.\nA Reset will cause SyncMemo32 to reexamine ALL " .
"memos on the Pilot instead of just\nthose that have changed. " .
"Blowing away either the Pilot or Files will cause ALL memos\n" .
"in that database to be deleted and replaced with the contents " .
@@ -310,8 +313,8 @@
$obj->pack(-anchor => "center");
$subfr = $frame->Frame;
- $obj = TkUtils::Button($subfr, "Reset SyncMemo",
- sub{ $gYesNoDialog->configure(-title => "Reset SyncMemo");
+ $obj = TkUtils::Button($subfr, "Reset SyncMemo32",
+ sub{ $gYesNoDialog->configure(-title => "Reset SyncMemo32");
unlink ($PREFS->{"DBFILE"}) if ($gYesNoDialog->Show eq "Yes");
});
$obj->pack(-side => "left", -anchor => "w", -fill => "x");
@@ -495,9 +498,9 @@
{
$dlp->watchdog(20);
$i = PilotMgr::askUser("Your last sync was either " .
- "unsuccessful or did not include SyncMemo. If you have " .
+ "unsuccessful or did not include SyncMemo32. If you have " .
"done any memo sync operations to another machine or " .
- "restored an old MemoDB file you should do a full sync " .
+ "restored an old Memo32DB file you should do a full sync " .
"now. Otherwise a fast sync is still safe...",
'Fast Sync', 'Full Sync');
$dlp->watchdog(0);
@@ -559,7 +562,7 @@
{
unless ($count % &fake_ceil($count_max / 20))
{
- PilotMgr::status("Synchronizing Memos",
+ PilotMgr::status("Synchronizing Memos32",
int (100 * $count / $count_max));
}
$dlp->tickle unless (++$count % 40);
@@ -694,7 +697,7 @@
{
$ret = PDA::Pilot::errorText($ret);
PilotMgr::msg("Error $ret writing $file to pilot.");
- $dlp->log("SyncMemo: Error $ret writing $file to pilot.");
+ $dlp->log("SyncMemo32: Error $ret writing $file to pilot.");
$newsum{$file} = $oldsum{$file};
delete $oldsum{$file};
next;
@@ -731,7 +734,7 @@
{
$ret = PDA::Pilot::errorText($ret);
PilotMgr::msg("Error $ret deleting pilot record $piid{$file}!!");
- $dlp->log("SyncMemo: Error $ret deleting pilot record " .
+ $dlp->log("SyncMemo32: Error $ret deleting pilot record " .
$piid{$file});
}
$cnt++;
--
Bodo Bellut bodo@xxxxxxxxxx | USE PGP! +-----------+
Klosterstr. 7 | (key via server |\ O---m /|
44135 Dortmund Fon: +49-231-5860337 | or on request) |/---------\|
PGP: 768/FA18A639 AE 5A 47 40 5A A0 D6 15 8E 54 44 AA 8D DD 6E BD+-----------+
------------------------------------------------------------------------
***********************************************************
* This is a public mailing list! *
* Please do not publish Sun proprietary information here! *
* - - - - - - - - - - - - - - *
* MoreInfo/Unsubscribe @ http://www.moshpit.org/pilotmgr *
***********************************************************
|
|