[rkward-cvs] SF.net SVN: rkward:[2969] trunk/rkward/rkward/rbackend/rpackages/rkward/R/ public_graphics.R
kapatp at users.sourceforge.net
kapatp at users.sourceforge.net
Fri Aug 27 21:03:38 UTC 2010
Revision: 2969
http://rkward.svn.sourceforge.net/rkward/?rev=2969&view=rev
Author: kapatp
Date: 2010-08-27 21:03:38 +0000 (Fri, 27 Aug 2010)
Log Message:
-----------
Fix an error while setting trellis.last.object
Modified Paths:
--------------
trunk/rkward/rkward/rbackend/rpackages/rkward/R/public_graphics.R
Modified: trunk/rkward/rkward/rbackend/rpackages/rkward/R/public_graphics.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkward/R/public_graphics.R 2010-08-26 06:40:19 UTC (rev 2968)
+++ trunk/rkward/rkward/rbackend/rpackages/rkward/R/public_graphics.R 2010-08-27 21:03:38 UTC (rev 2969)
@@ -83,8 +83,9 @@
.set.gType.newplot <- function (x) gType.newplot <<- x
.set.trellis.last.object <- function (deviceId = dev.cur ())
{
- if (gType[[deviceId]] == "lattice")
- assign ("last.object", recorded[[deviceId]], envir = lattice:::.LatticeEnv)
+ deviceId <- as.character (deviceId)
+ if (gType[[histPositions [[deviceId]]]] == "lattice")
+ assign ("last.object", recorded[[histPositions [[deviceId]]]], envir = lattice:::.LatticeEnv)
invisible ()
}
onAddDevice <- function (old_dev = 1, deviceId = dev.cur ())
@@ -298,7 +299,7 @@
replayPlot (recorded[[n]])
} else if (gType [[n]] == "lattice") {
message (deparse (recorded[[n]]$call)) # show case call object
- plot (recorded[[n]])
+ plot (recorded[[n]], save.object = (cur.deviceId == as.numeric (deviceId)))
}
histPositions [[deviceId]] <<- n
.set.gType.newplot (gType [[n]])
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the rkward-tracker
mailing list